Anime_up_updater is a simple script python able to collect informations about anime that actually in airing
arount the globe. Go and check it if you are a fan!
The project has been built with poetry and docker. So for executing is necessary to install both.
To install, from the main proj folder, follows this steps:
- Visit the Poetry website to download the installer for your operating system.
- Run the installer according to the instructions provided for your operating system.
- After installation, verify that Poetry is installed correctly by opening a terminal or command prompt and typing:
poetry --version
This command should display the installed version of Poetry. For more detailed installation instructions and usage guidelines, refer to the Poetry Installation Guide.
Then for installing the project:
# in case you are using vscode: this will make vsCode recognise and create the .venv
poetry config virtualenvs.in-project true
# create virtual env
poetry install
# activate the env
poetry shell
Then you are ready to launch it!
To use also the storage in mongo, can be usefull to install docker-desktop. Here the steps:
-
Download Docker Desktop: Go to the official Docker website: Docker-Desktop. Click on the "Download for Mac" or "Download for Windows" button, depending on your operating system.
-
Install Docker Desktop: Once the download is complete, double-click the downloaded file to start the installation process.
In case of MacOs you can do it with brew. To install Docker Desktop using Homebrew on macOS, open the terminal and type:
brew update brew install --cask docker
-
Launch Docker Desktop: After the installation is complete, launch Docker Desktop from your applications menu or desktop shortcut.
-
Verify Installation: Open a terminal or command prompt and run the following command to verify that Docker is installed and running correctly:
docker --version
Then you are ready. So before launching the script just type in your terminal (inside the proj folder):
docker compose up --build -d
This will start a detached docker container with your mongo db.
After the configuration you can execute the script by typing:
poetry run script
This is the general way of using it. It will create a local file called for example airing_anime_list_31-07_4_2024
containing the unfiltered anime list. This is a local file that will be used by the script to not re-download the data all the time (avoiding ban).
To have the filtered one is important to add the parameter --filter-result
to the bash in addition to the specification of where to store it.
Actually you have 2 ways to store it:
-
Storing data in db
poetry run script --db-conn-str "mongodb://localhost:27017/" --database "anime_up" --collection "my_airing_anime"
In case you dont specify
database
andcollection
the default one will be chosen: "anime_up" for the db and "airing_anime" for the collection. As reported before, the code provides a simple docker-compose with a mongodb in case you want to test it. Just typedocker-compose up -d
to launch it. I will not provide any additional info on docker and docker compose usage. -
Storing data into a specific file
poetry run script --output-file "/Users/someone/Desktop"
We welcome contributions to our project! If you would like to contribute, please follow these guidelines:
If you encounter any issues with the project, please feel free to report them here. When reporting issues, please include detailed information such as steps to reproduce the problem, expected behavior, and actual behavior.
If you would like to contribute code to the project, you can submit a pull request. Here's how:
- Fork the project repository.
- Create a new branch for your feature or bug fix.
- Make your changes and commit them to your branch.
- Push your changes to your fork.
- Submit a pull request to the main project repository.
Please make sure your code follows our coding standards and includes appropriate documentation. We'll review your pull request and provide feedback as needed.
Thank you for contributing to our project!
This project is licensed under the MIT License. You are free to use, modify, and distribute the code for both commercial and non-commercial purposes. See the LICENSE file for more details.
- Suggest me something