Question: many webpages use onload JavaScript to manipulate their DOM. Is there a way I can automate accessing the state of the HTML after these JavaScript operations?

A took like wget is not useful here because it just downloads the original source. 
Is there perhaps a way to use a web browser rendering engine?

Ideally I am after a solution that I can interface with from Python.

thanks!

Answer: 
The only good way I know to do such things is to automate a browser, for example via [Selenium RC](http://seleniumhq.org/projects/remote-control/). If you have no idea of how to deduce that the page has finished running the relevant javascript, then, just a real live user visiting that page, you'll just have to wait a while, grab a snapshot, wait some more, grab another, and check there was no change between them to convince yourself that it's really finished.
Please see related info at stackoverflow:

* [screen-scraping](https://stackoverflow.com/questions/tagged/screen-scraping)
* [Screen Scraping from a web page with a lot of Javascript](https://stackoverflow.com/questions/857515/screen-scraping-from-a-web-page-with-a-lot-of-javascript)