GithubHelp home page GithubHelp logo

pymtgfall's Introduction

PyMtgFall

This is a personal project to create a python library for easy access to scryfall.


Road to v1.0.0

Features I want to ship with v1.0.0

  • Potentially treat API errors the same as other data, as the API does?
  • Potentially deal with images?
  • Download Bulk Data and Switch automatically between
    1. Cache
    2. Downloaded Bulk Data
    3. Potentially download the Bulk Data
    4. Finally API
  • 100% Code Coverage
    1. Tests (Mocked)
    2. Tests (Integration)
  • 100% Typed
    1. MyPy
    2. Pylint
    3. Black
  • Documentation
  • To fill this list

Dev Getting Started

Steps:

  1. Install Poetry
  2. Optional: Set poetry to make an in project venv with poetry config virtualenvs.in-project true
  3. Run poetry install
  4. Run poetry run pre-commit install
  5. Edit files
  6. Run poetry run python <file>
  7. Run poetry run pre-commit to lint, format, generate requirements.txt, and more.
  8. On commit: see committing section

Committing:

This repo uses pre-commit to run Mypy, Pylint, Black, build requirements.txt, check pyproject.toml vs poetry, and isort at time of commit.
Commit will run black on all files, sort imports, and generate requirements.txt. Make sure requirements.txt is added and re-commit
This can be avoided by running poetry run pre-commit

Commands:

poetry add/remove <library> [--dev] to add or remove dev dependency.
poetry run pytest to run pytest with coverage and generate HTML report in htmlcov/
poetry run black . to black format code.
poetry run pre-commit to run all of the pre-commit checks. Will modify files and generate some.
poetry run python <script> to use the environment to run code.


Changes from API

Some words are reserved by python, so they are translated.

Data:
"id" = "api_id"
"object" = "obj"
"format" = "format_response"
"dir" = "direction"
"set" = "set_code"
"type" = "api_type"
"q" = "query" # One letter variables are not ideal

Objects:
"list" = "APIList"

pymtgfall's People

Contributors

padilin avatar

Watchers

 avatar

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.