Today we’ll spend some time looking at three different ways to make Python submit a web form. In this case, we will be doing a web search with duckduckgo.com searching on the term “python” and saving the result as an HTML file. We will use Python’s included urllib modules and two 3rd party packages: requests and mechanize. We have three small scripts to cover, so let’s get cracking! Continue reading Python 101: How to submit a web form
This week there were several fun things to read about in the Python ecosystem. You can read about a cool new Mercurial mirror of the Python repo, discover simple queues with redis and learn how to take an SQL statement and reverse engineer it into SQLAlchemy code. I’m not sure why you’d do that last one as I seem to recall SQLALchemy being able to support straight SQL, but it’s still an interesting article. Besides those, I have a few others you might find interesting too!
- Mercurial Mirrors Provided by Atlassian
- Simple Python Queue with Redis
- Calculating pi with AGM and mpmath
- Automatic reconnect in MySQL Connector/Python?
- Eval really is dangerous (Ned Batchelder)
- Sqlalchemy In Reverse
- Screen Scraping
I’ll probably be skipping this post next week as it’s going to be extremely busy. I hope you enjoy this week’s reading list though. Feel free to let me know what you’ve been reading too.