title-belt-nhl


Nametitle-belt-nhl JSON
Version 0.3.6 PyPI version JSON
download
home_pageNone
SummaryCLI tool to compute NHL Title Belt info.
upload_time2024-11-21 13:37:46
maintainerNone
docs_urlNone
authorkawa2287
requires_python<4.0,>=3.10
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Title Belt Calculator

Finds the shortest path to having a shot at the belt for a given team and belt holder.

## Setup

```
poetry install

# either open a poetry shell to run everything
poetry shell

# or run individual commands with the poetry run prefix
poetry run title-belt-nhl
```

The following steps assume you are in a poetry shell.
Add `poetry run ` at the beginning of commands if not.

## Usage

Run with `title-belt-nhl`.

```
$ title-belt-nhl --help

Usage: title-belt-nhl [OPTIONS]

Options:
  --team TEXT    [required]
  --season TEXT
  --help         Show this message and exit.

Commands:
  belt-path
  path
  path-alt
```

* use `path-alt` to get a list of games recursively
* use `path` to get the nested list of games iteratively, containing all evaluated games with the shortest path marked
* use `belt-path` to get the list of complete games that the belt has traveled so far, plus the next title belt match

## Linting and Formatting

### Linting

`ruff check title_belt_nhl`

#### Fix Lint Errors

`ruff check --fix title_belt_nhl`

### Formatting

`ruff format title_belt_nhl`

#### Autoformat on save (vscode)

1. Install `ruff` extension
1. Update settings in `.vscode/settings.json`:
    ```
    {
        "[python]": {
          "editor.formatOnSave": true,
          "editor.defaultFormatter": "charliermarsh.ruff",
          "editor.codeActionsOnSave": {
            "source.fixAll": "explicit"
          }
        }
    }
    ```
1. Ensure you are using the python interpreter from the poetry shell.
    - Open command palette (Ctrl+Shift+P)
    - `Python: Select Interpreter`
    - "Select at workspace level"
    - "Enter interpreter path"
    - Copy/paste the path to your poetry virtualenv
      - Run `poetry env info` and copy the path to the Executable under **Virtualenv**
      - Should be something like `/home/user/.cache/pypoetry/virtualenvs/title-belt-nhl-asdf1234-py3.10/bin/python`
  
    -  When you open a python file in vscode, the bottom right corner of the window should show something like:
        ```
        Python  3.10.14 ("title-belt-nhl-asdf1234-py3.10": poetry)
        ```

## Testing

Run `poetry run pytest` to run through any tests in the `./title_belt_nhl/tests` folder


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "title-belt-nhl",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.10",
    "maintainer_email": null,
    "keywords": null,
    "author": "kawa2287",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/b3/14/43a750216f89e52cd0168e50304304faa54fab8a56d8d1fb6c1e1300b6f6/title_belt_nhl-0.3.6.tar.gz",
    "platform": null,
    "description": "# Title Belt Calculator\n\nFinds the shortest path to having a shot at the belt for a given team and belt holder.\n\n## Setup\n\n```\npoetry install\n\n# either open a poetry shell to run everything\npoetry shell\n\n# or run individual commands with the poetry run prefix\npoetry run title-belt-nhl\n```\n\nThe following steps assume you are in a poetry shell.\nAdd `poetry run ` at the beginning of commands if not.\n\n## Usage\n\nRun with `title-belt-nhl`.\n\n```\n$ title-belt-nhl --help\n\nUsage: title-belt-nhl [OPTIONS]\n\nOptions:\n  --team TEXT    [required]\n  --season TEXT\n  --help         Show this message and exit.\n\nCommands:\n  belt-path\n  path\n  path-alt\n```\n\n* use `path-alt` to get a list of games recursively\n* use `path` to get the nested list of games iteratively, containing all evaluated games with the shortest path marked\n* use `belt-path` to get the list of complete games that the belt has traveled so far, plus the next title belt match\n\n## Linting and Formatting\n\n### Linting\n\n`ruff check title_belt_nhl`\n\n#### Fix Lint Errors\n\n`ruff check --fix title_belt_nhl`\n\n### Formatting\n\n`ruff format title_belt_nhl`\n\n#### Autoformat on save (vscode)\n\n1. Install `ruff` extension\n1. Update settings in `.vscode/settings.json`:\n    ```\n    {\n        \"[python]\": {\n          \"editor.formatOnSave\": true,\n          \"editor.defaultFormatter\": \"charliermarsh.ruff\",\n          \"editor.codeActionsOnSave\": {\n            \"source.fixAll\": \"explicit\"\n          }\n        }\n    }\n    ```\n1. Ensure you are using the python interpreter from the poetry shell.\n    - Open command palette (Ctrl+Shift+P)\n    - `Python: Select Interpreter`\n    - \"Select at workspace level\"\n    - \"Enter interpreter path\"\n    - Copy/paste the path to your poetry virtualenv\n      - Run `poetry env info` and copy the path to the Executable under **Virtualenv**\n      - Should be something like `/home/user/.cache/pypoetry/virtualenvs/title-belt-nhl-asdf1234-py3.10/bin/python`\n  \n    -  When you open a python file in vscode, the bottom right corner of the window should show something like:\n        ```\n        Python  3.10.14 (\"title-belt-nhl-asdf1234-py3.10\": poetry)\n        ```\n\n## Testing\n\nRun `poetry run pytest` to run through any tests in the `./title_belt_nhl/tests` folder\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "CLI tool to compute NHL Title Belt info.",
    "version": "0.3.6",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4c1ba1bc811fc7885778c6afd2738cfe854e45048b126065748fa62f2eec16b0",
                "md5": "4c8a2b914208d17b1f8da89523ef3bd6",
                "sha256": "1dc59784bb23f562bbd25e236fa13460ebd8e31c4c1b706953995b399b4a9ac0"
            },
            "downloads": -1,
            "filename": "title_belt_nhl-0.3.6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4c8a2b914208d17b1f8da89523ef3bd6",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.10",
            "size": 31782,
            "upload_time": "2024-11-21T13:37:44",
            "upload_time_iso_8601": "2024-11-21T13:37:44.904544Z",
            "url": "https://files.pythonhosted.org/packages/4c/1b/a1bc811fc7885778c6afd2738cfe854e45048b126065748fa62f2eec16b0/title_belt_nhl-0.3.6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b31443a750216f89e52cd0168e50304304faa54fab8a56d8d1fb6c1e1300b6f6",
                "md5": "d200de0f6933772362dd0a39c595f280",
                "sha256": "c467d1b634cb2ba6c1a3c9340c94f9b2fa3e91f37885cf60bd06f4403767223e"
            },
            "downloads": -1,
            "filename": "title_belt_nhl-0.3.6.tar.gz",
            "has_sig": false,
            "md5_digest": "d200de0f6933772362dd0a39c595f280",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.10",
            "size": 30394,
            "upload_time": "2024-11-21T13:37:46",
            "upload_time_iso_8601": "2024-11-21T13:37:46.212332Z",
            "url": "https://files.pythonhosted.org/packages/b3/14/43a750216f89e52cd0168e50304304faa54fab8a56d8d1fb6c1e1300b6f6/title_belt_nhl-0.3.6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-21 13:37:46",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "title-belt-nhl"
}
        
Elapsed time: 0.33917s