Skip to content

Conversation

@Maneesh-Relanto
Copy link
Owner

  • Replace deprecated datetime.utcnow() with datetime.now(timezone.utc)
  • Add timezone-aware datetime defaults in models
  • Extract duplicate string literals to constants (ERROR_NOT_FOUND, ERROR_VALIDATION, MSG_POST_NOT_FOUND)
  • Remove unused variables (post, old_role_id, data, permission)
  • Fix bare except clause to specify Exception type
  • Fix type hints (str | None return type)
  • Remove unnecessary f-strings
  • Improve code maintainability and Python 3.12+ compatibility
  • Tests: 30 passing (4 pre-existing ownership check failures)

- Replace deprecated datetime.utcnow() with datetime.now(timezone.utc)
- Add timezone-aware datetime defaults in models
- Extract duplicate string literals to constants (ERROR_NOT_FOUND, ERROR_VALIDATION, MSG_POST_NOT_FOUND)
- Remove unused variables (post, old_role_id, data, permission)
- Fix bare except clause to specify Exception type
- Fix type hints (str | None return type)
- Remove unnecessary f-strings
- Improve code maintainability and Python 3.12+ compatibility
- Tests: 30 passing (4 pre-existing ownership check failures)
@Maneesh-Relanto Maneesh-Relanto merged commit c00aa22 into main Feb 2, 2026
0 of 7 checks passed
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.

1 participant