Sign inSign up

yakimka/cs-wayback-machine

By yakimka

•Updated 11 months ago

Image
0

1.3K

yakimka/cs-wayback-machine repository overview

⁠Counter-Strike Wayback Machine

Build Status Codecov

A Service for Viewing Historical Data on Counter-Strike Players and Teams

This service allows you to explore team rosters during different time periods, view the teammates of a specific professional player, and more.

⁠Used Technologies

⁠Docker images

Docker images (amd64 and arm64) are available on Docker Hub⁠.

⁠Development

⁠Quick Start
  1. Clone the repository:
    git clone <repository-url>
    
  2. Copy the example settings file and configure your settings:
    cp cs_wayback_machine/settings.example.yaml cs_wayback_machine/settings.yaml
    
  3. Build the Docker images:
    docker-compose build
    
  4. Start the service:
    docker-compose up
    
⁠Making Changes
  1. List available make commands:

    make help
    
  2. Check code style with:

    make lint
    
  3. Run tests using:

    make test
    
  4. Manage dependencies via Poetry:

    make poetry args="<poetry-args>"
    
    • For example: make poetry args="add requests"
    • Rebuild the Docker image after modifying dependencies.
  5. For local CI debugging:

    make run-ci
    
⁠Pre-commit Hooks

We use pre-commit⁠ for linting and formatting:

  • It runs inside a Docker container by default.
  • Optionally, set up hooks locally:
    pre-commit install
    
⁠Mypy

We use mypy⁠ for static type checking.

It is configured for strictly typed code, so you may need to add type hints to your code. But don't be very strict, sometimes it's better to use Any type.

Also, if you don't feel comfortable with that strictness, you can disable some checks in the pyproject.toml⁠ in tool.mypy section:

  • disallow_untyped_calls = false
  • disallow_untyped_decorators = false
  • disallow_untyped_defs = false

⁠Available CLI Commands

Project CLI commands are available in the cs_wayback_machine.cli module. List of available commands you can see if you run python -m cs_wayback_machine.cli --help command.

⁠update_database

Command for updating the database with new data from Liquipedia. This command is starting Scrapy spider for parsing data from Liquipedia and updating the database.

Can also be used like cron job with --schedule option.

⁠License

MIT⁠

⁠Credits

This project was generated with yakimka/cookiecutter-pyproject⁠.

Tag summary

Content type

Image

Digest

sha256:646a1c558…

Size

90.6 MB

Last updated

11 months ago

docker pull yakimka/cs-wayback-machine