inovintell / py-template Goto Github PK
View Code? Open in Web Editor NEWOne-click GitHub Actions pipelines for Python!
Home Page: https://inovintell.github.io/docs-template/
License: Apache License 2.0
One-click GitHub Actions pipelines for Python!
Home Page: https://inovintell.github.io/docs-template/
License: Apache License 2.0
Currently main
group of poetry dependencies is not installed within CI, it should be added.
Currently when Python projects are run, poetry.lock
is automatically
updated during linting (and other tests) as the pipeline is using
pre-commit
.
We should disable tests
(as these are run by separate workflow)
and poetry lock
automated check (as these should be mostly local).
Currently __init__.py
is exempt from the import checks, #noqa is redundant and actually remove by ruff
during first commit.
Feedback from the first failing test suites might not be enough, hence we should switch to
to running all test runners even if some of them fail.
Currently all of the test have Python 3.x
(3.11
) for the test runners, while these should be tailored to specific Python version within os.matrix
during CI.
Check whether scraping flake
and flakeheaven
for ruff would not be the best idea to proceed.
Difficulty will emerge when choosing rules as most of that has to be hand verified.
Currently precommit runs on all files in some cases, which is unnecessary (as only the ones affected
should be checked).
pytest
should be run on the whole test suite, as it is currently impossible to infer whether
any changes in src
influenced existing tests.
yamllint
has no files provided during CI run, simply add .
The style in which violation messages are presented by Ruff is indicated by the keyword "format" inside pyproject.toml, as shown below:
[tool.ruff]
format = "grouped"
Previously, this configuration used to work in our template. However, recently, it causes a failure with the following error:
Cause: TOML parse error at line 126, column 10
|
126 | format = "grouped"
|
invalid type: string "grouped", expected struct FormatOptions
Upon investigating the documentation, I found that the correct keyword should be "output-format" instead of "format".
I suggest updating the configuration in pyproject.toml to reflect the correct keyword "output-format" as follows:
[tool.ruff]
output-format = "grouped"
This change should resolve the parsing error and align with the documentation's requirements.
Define a few aliases which might come handy when working with py-template.
Currently coverage is bugged and calculated across test
folder instead of src
Currently some actions are run only when /tests
are changed, these references should be changed to /test
.
Only pytype
does not support Python 3.11 currently, we can
specify this dependency explicitly.
Adjustments to installed packages within tests
might have to be
required due to above (e.g. installation of specific additional
dependencies instead of --all-extras
)
Currently code-linter
checks docstrings
coverage, we can safely
remove this action.
Currently Python version support is not unified across py-template
.
In order to align with most of the (scientific) Python, we should settle on
Python 3.9 or above, according to NEP29
Remove leftover rules from flake8
Forward existing files and check their compliance with current YAML standard
Currently pytest
tests will raise error if any assert
is used.
Exclude ruff S101
for these files.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.