Simplifying Classes, Cleaner Interface

June 05, 2017

I did some restructuring today. Figured out that the best approach would be to keep all my main objects in the file.

So I deleted and moved it into a Database class in the sps module.
I create a Scraper object and a Database object to use.
Now it’s a cleaner interface, yay.

import sps

scraper = sps.Scraper()

database = sps.Database()

report = scraper.inventory_report()


Keep it as simple as possible, until I’m forced to bring in complexity.

Next steps is to figure out how to get the add_report (a wrapper around to_sql pandas method) method to use the already-defined schemas in

Right now, a schema is created based on the pandas dataframe, which is not ideal.