Skip to content

Commit

Permalink
Bump ruff from 0.1.13 to 0.1.14 (#8)
Browse files Browse the repository at this point in the history
* Bump ruff from 0.1.13 to 0.1.14

Bumps [ruff](https://github.com/astral-sh/ruff) from 0.1.13 to 0.1.14.
- [Release notes](https://github.com/astral-sh/ruff/releases)
- [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md)
- [Commits](astral-sh/ruff@v0.1.13...v0.1.14)

---
updated-dependencies:
- dependency-name: ruff
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>

* Update import statement and reorder exceptions list

An import statement in 'stepik_plugins_client/rpcapi.py' was updated to handle the linter warning. Also, rearranged the exceptions list in 'stepic_plugins/exceptions.py' for clarity and ease of use.

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: meanmail <[email protected]>
  • Loading branch information
dependabot[bot] and meanmail authored Jan 25, 2024
1 parent 7f80cb6 commit 5c5ef59
Show file tree
Hide file tree
Showing 6 changed files with 83 additions and 24 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/auto-author-assign.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Auto Author Assign

on:
pull_request_target:
types: [ opened, reopened ]

permissions:
pull-requests: write

jobs:
assign-author:
runs-on: [self-hosted, small]
timeout-minutes: 30
if: ${{ !github.event.pull_request.assignee }}
steps:
- uses: toshimaru/[email protected]
43 changes: 43 additions & 0 deletions .github/workflows/auto-format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Format code
on:
pull_request:
push:
branches:
- 'master'

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true

jobs:
format_backend:
name: Format with ruff
runs-on: [ self-hosted, small ]
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}

- name: Install Poetry
run: pipx install poetry==$(head -n 1 .poetry-version)

- uses: actions/setup-python@v5
with:
python-version-file: '.python-version'
cache: 'poetry'

- name: Install dependencies
run: poetry install --only main,dev --no-interaction --no-ansi

- run: poetry run ruff --fix --unsafe-fixes --preview --exit-zero .
- run: poetry run ruff format .

- name: Commit changes
uses: EndBug/add-and-commit@v9
with:
fetch: false
default_author: github_actions
message: 'Backend: Auto format'
add: '.'
39 changes: 20 additions & 19 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@ structlog = ">=23.1.0"
voluptuous = "^0.14.1"

[tool.poetry.group.dev.dependencies]
black = "^23.3.0"
mypy = "^1.4.1"
ruff = "^0.1.13"
ruff = "^0.1.14"
types-pytz = ">=2023.3.0.0"

[build-system]
Expand Down
4 changes: 2 additions & 2 deletions stepic_plugins/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
)

__all__ = [
"PluginError",
"FormatError",
"PluginError",
"PluginTimeoutError",
"QuizSetUpError",
"UnknownPluginError",
"PluginTimeoutError",
]
2 changes: 1 addition & 1 deletion stepik_plugins_client/rpcapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import oslo_messaging as messaging
from oslo_config import cfg
from oslo_messaging.rpc.client import _client_opts
from oslo_messaging.rpc.client import _client_opts # noqa: PLC2701

from stepik_plugins_client.schema import RPCSerializer

Expand Down

0 comments on commit 5c5ef59

Please sign in to comment.