Skip to content

fix: resolve Ruff violations in playground/backend_manager - #67

Open
swadhinbiswas wants to merge 1 commit into
google:mainfrom
swadhinbiswas:fix/ruff-playground-backend-manager
Open

swadhinbiswas wants to merge 1 commit into
google:mainfrom
swadhinbiswas:fix/ruff-playground-backend-manager

Conversation

@swadhinbiswas

Copy link
Copy Markdown

Summary

Fixes the CI Lint Python failure on main: uv run ruff check . reports 11 errors in playground/backend_manager.

  • UP017: use the datetime.UTC alias instead of timezone.utc
  • UP045 / UP037: use X | None instead of Optional["X"]
  • Remove the now-unused timezone, Optional, and datetime imports

Files changed

  • playground/backend_manager/app/auth/jwt_handler.py
  • playground/backend_manager/app/auth/otp_service.py
  • playground/backend_manager/app/services/session_manager.py
  • playground/backend_manager/app/services/bigquery_service.py
  • playground/backend_manager/app/services/docker_service.py

Verification

  • uv run ruff check . → All checks passed
  • uv run ruff format --check . → 616 files already formatted

Modernize datetime/typing usage in playground/backend_manager so CI's
`ruff check .` and `ruff format --check .` pass:

- datetime.now(timezone.utc) -> datetime.now(UTC)
- Optional["X"] -> X | None
- drop now-unused timezone/Optional/datetime imports
@google-cla

google-cla Bot commented Sep 12, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Uzzoper added a commit to Uzzoper/artemis that referenced this pull request Sep 26, 2026
…d_manager

Mechanical ruff check --fix plus format for the 11 errors keeping python-quality red on main (same as stalled google#30/google#67). Split out from the google#129 feature for scope discipline.
@Uzzoper

Uzzoper commented Sep 27, 2026

Copy link
Copy Markdown

Heads-up: #155 (fix for #129) had to include the same mechanical ruff fix for playground/backend_manager as a separate commit, because main's python-quality is red without it. Your PR was first — if it merges first, I'll gladly drop ours in a rebase and keep #155 to the feature only. Flagging so maintainers can treat whichever lands first as canonical.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants