This is pure python 3 template for new projects and bots on GitHub.
🚧 CI and deploy
After creating repo from the template make sure that you have correctly filled TARGET_WORKFLOW field in:
- .github/workflows/ci-dev.yml
- .github/workflows/ci-staging.yml
- .github/workflows/ci-prod.yml
DO NOT FORK this is meant to be used from Use this template feature.
- Click on Use this template
- Give a name to your project
(e.g.my_awesome_project
recommendation is to use all lowercase and underscores separation for repository names.) - Rename
myproject
to{your_project_name}
- Then clone your new project and happy coding!
List of secrets that you should add to secrets
- TARGET_REPO - Repository with our infra (lidofinance/infra-mainnet). This var need to run workflows from target repository.
- APP_ID and APP_PRIVATE_KEY - are ID and key to application that calls workflows in another application.
- 🐋 A simple Dockerfile to build a container image for your project.
- 🧪 Testing structure using pytest.
- 🔄 Continuous integration using GitHub Actions with jobs to lint, tests.
- 🌊 Tracking and logging via Prometheus.
- 🦸 Lint everything with lido linters.
Myproject is a base template for all python project with preinstalled packages that are common for Lido's codebase.
poetry install
- to install dep
from myproject import BaseClass
from myproject import base_function
BaseClass().base_method()
base_function()
$ python -m myproject
Hello world!
To create new release:
- Merge all changes to the
main
branch - Navigate to Repo => Actions
- Run action "Prepare release" action against
main
branch - When action execution is finished, navigate to Repo => Pull requests
- Find pull request named "chore(release): X.X.X" review and merge it with "Rebase and merge" (or "Squash and merge")
- After merge release action will be triggered automatically
- Navigate to Repo => Actions and see last actions logs for further details