Skip to main content

Download and read files from the web.

Project description

WebFiles

Download files hosted on the internet and parse with python

Core class construct:

import wget

class WebFile:
    def __init__(self, http_address, local_path=None):
        
        self.http_address = http_address
        if local_path:
            self.local_path = local_path
        else:
            self.local_path = os.path.basename(http_address)
            
    def download(self):
        if not os.path.exists(self.local_path):
            wget.download(self.http_address, self.local_path, bar=False)
            

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

WebFiles-0.0.1.tar.gz (2.9 kB view hashes)

Uploaded Source

Built Distribution

WebFiles-0.0.1-py3-none-any.whl (4.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page