Working with CSV or TSV files, we often ought to ignore the header row (aka. the column headers) before reading the rest of the file. To strip out the first…
Category: Python
How To Check If Key Exists In Dictionary In Python
If you try to retrieve a non-existed key of a dictionary, you are gonna stuck an exception obviously. To be get safer, you should do check its existence before doing…
Scraping and downloading multiple files from web with Python
In recent posts, we have discussed some methods to scrap and download resources from the web. If you just want to download a few files, it doesn’t matter to iterate…
An introduction to Selenium with Python
https://selenium-python.readthedocs.io/index.html
Parse HTML Document using XPath with lxml in Python
As long as we find a webpage where having data of interest, we sometimes want to extract them automatically but don’t know how to do quickly. Thank to the lxml…
Download Files in Python using the urllib Module
In the former posts, we have shared the methods to download files from the web using the requests or wget module. As we know, they are external modules which we…
Downloading Files in Python Using wget Module
In a recent post about downloading files in Python, we have learned how to use the requests module to check downloadable resources and restrict some measures to grab remote files.…
Downloading Files In Python Using Requests Module
This post aims to present you how to download a resource from the given URL using the requests module. Of course, there are other modules which allow you to accomplish…
How to create a temporary file to store data
Your application has to write data out in a temporary file to reprocess them before rendering to users. The file will be created temporarily and swept our when the application…