Skip to content

fix(core): use aware UTC timestamps#193

Merged
dextmorgn merged 1 commit into
reconurge:mainfrom
Ghraven:fix/core-aware-utc-cutoffs
Jun 24, 2026
Merged

fix(core): use aware UTC timestamps#193
dextmorgn merged 1 commit into
reconurge:mainfrom
Ghraven:fix/core-aware-utc-cutoffs

Conversation

@Ghraven

@Ghraven Ghraven commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Problem: two core timestamp paths still used datetime.utcnow(): JWT expiration in create_access_token() and the default 24-hour cutoff in LogRepository.get_by_sketch(). The project already uses timezone-aware UTC timestamps in nearby core services and models.

Before / after: before, both paths produced naive UTC datetimes. After, they use datetime.now(timezone.utc), matching the repo's timezone-aware timestamp style while preserving the same expiry duration and one-day log cutoff behavior.

Verification:

  • python -m py_compile flowsint-core\src\flowsint_core\core\auth.py flowsint-core\src\flowsint_core\core\repositories\log_repository.py
  • Tried python -m pytest flowsint-core\tests\repositories\test_log_repository.py with source paths configured, but this local environment is missing passlib, so the test run stops during import before executing tests.

@dextmorgn dextmorgn left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks !

@dextmorgn dextmorgn merged commit e02d548 into reconurge:main Jun 24, 2026
1 check 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.

2 participants