Git Product home page Git Product logo

bolero's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

c4p-n1ck

bolero's Issues

Clearer permission system

Currently, permissions is handled at the tracker implementation level (check_auth is set as a request preprocessor in Tracker.create_api()).

This should be changed so that tracker permissions can be set at the tracker configuration level (i.e. config.json)

Rework Tracker loading

Per #1, trackers will be objects instead of modules.

Thus, tracker loading will need to be updated from the naive importlib.import_module approach.

It will probably be sufficient to do something like youtube-dl's mass-import, and then selectively authenticate / activate the enabled trackers.

Standardize tracker object / behavior

Trackers should be objects, instead of formless modules. They behave more like objects already, and it's more idiomatic to call duck-typed functions of a subclass to Tracker than to a module.

Trackers should be able to do the following:

  • Authenticate the API client
    • handleAuthentication()
  • Do some type of regular scraping function
    • scrape()
  • Do a complete 'refresh' of their object's database
    • backfill()

Trackers should be distinct from their associated models, and should only have simple CRUD tasks on the actual data.

Further decouple plugins from "core"

Plugins should be more like plugins than internal modules.
It's fine to have a list of modules as strings in a configuration file and import them via __import__.

The idea is to have bolero be a relatively lean framework, and push a lot of the complexity / implementation out to the tracker plugins.

Improve testing

Next big push is to get the actual tests working.
#3 reduced the dependencies between the app and trackers, so it should be possible to unit test the trackers without having to load / startup the app. (If it isn't, then that's something to do too)

Not sure how much testing is necessary for an external api driven project like this, but something better than running the updateall cli command would be good. ๐Ÿ‘

Myfitnesspal Tracker backfill range

MyFitnessPalTracker.backfill should find the user's earliest logged day and start backfilling from there.

This is a bit difficult due to the way that the python module used to connect with MFP is structured.
Right now, we're just naively grabbing the last 1 year of history.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.