forked from hgrecco/pint
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
199 changed files
with
17,296 additions
and
9,639 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,23 @@ | ||
[run] | ||
omit = pint/testsuite/* | ||
omit = | ||
pint/testsuite/* | ||
pint/_vendor/* | ||
|
||
[report] | ||
# Regexes for lines to exclude from consideration | ||
exclude_lines = | ||
# Have to re-enable the standard pragma | ||
pragma: no cover | ||
|
||
# Don't complain about missing debug-only code: | ||
def __repr__ | ||
|
||
# Don't complain if tests don't hit defensive assertion code: | ||
raise AssertionError | ||
raise NotImplementedError | ||
AbstractMethodError | ||
|
||
# Don't complain if non-runnable code isn't run: | ||
if TYPE_CHECKING: | ||
|
||
return NotImplemented |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
- [ ] Closes # (insert issue number) | ||
- [ ] Executed ``pre-commit run --all-files`` with no errors | ||
- [ ] Executed `pre-commit run --all-files` with no errors | ||
- [ ] The change is fully covered by automated unit tests | ||
- [ ] Documented in docs/ as appropriate | ||
- [ ] Added an entry to the CHANGES file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: codspeed-benchmarks | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
- "develop" | ||
pull_request: | ||
# `workflow_dispatch` allows CodSpeed to trigger backtest | ||
# performance analysis in order to generate initial data. | ||
workflow_dispatch: | ||
|
||
jobs: | ||
benchmarks: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v3 | ||
with: | ||
python-version: "3.12" | ||
|
||
- name: Install dependencies | ||
run: pip install "numpy>=1.23,<2.0.0" | ||
|
||
- name: Install bench dependencies | ||
run: pip install .[bench] | ||
|
||
- name: Run benchmarks | ||
uses: CodSpeedHQ/action@v1 | ||
with: | ||
token: ${{ secrets.CODSPEED_TOKEN }} | ||
run: pytest . --codspeed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: pre-commit | ||
|
||
on: | ||
schedule: | ||
- cron: "0 0 * * 0" # every Sunday at 00:00 UTC | ||
workflow_dispatch: | ||
|
||
|
||
jobs: | ||
autoupdate: | ||
name: autoupdate | ||
runs-on: ubuntu-latest | ||
if: github.repository == 'hgrecco/pint' | ||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v2 | ||
- name: Cache pip and pre-commit | ||
uses: actions/cache@v2 | ||
with: | ||
path: | | ||
~/.cache/pre-commit | ||
~/.cache/pip | ||
key: ${{ runner.os }}-pre-commit-autoupdate | ||
- name: setup python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.x | ||
- name: upgrade pip | ||
run: python -m pip install --upgrade pip | ||
- name: install dependencies | ||
run: python -m pip install --upgrade pre-commit | ||
- name: version info | ||
run: python -m pip list | ||
- name: autoupdate | ||
uses: technote-space/create-pr-action@bfd4392c80dbeb54e0bacbcf4750540aecae6ed4 | ||
with: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
EXECUTE_COMMANDS: | | ||
python -m pre_commit autoupdate | ||
python -m pre_commit run --all-files | ||
COMMIT_MESSAGE: 'pre-commit: autoupdate hook versions' | ||
COMMIT_NAME: 'github-actions[bot]' | ||
COMMIT_EMAIL: 'github-actions[bot]@users.noreply.github.com' | ||
PR_TITLE: 'pre-commit: autoupdate hook versions' | ||
PR_BRANCH_PREFIX: 'pre-commit/' | ||
PR_BRANCH_NAME: 'autoupdate-${PR_ID}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,4 +14,4 @@ jobs: | |
- name: Lint | ||
uses: pre-commit/[email protected] | ||
with: | ||
extra_args: --all-files --show-diff-on-failure | ||
extra_args: --all-files --show-diff-on-failure |
Oops, something went wrong.