Skip to content

Fix/issue 58 auth tokens expire silently#17

Merged
Khamel83 merged 2 commits into
mainfrom
fix/issue-58-auth-tokens-expire-silently
Jun 6, 2026
Merged

Fix/issue 58 auth tokens expire silently#17
Khamel83 merged 2 commits into
mainfrom
fix/issue-58-auth-tokens-expire-silently

Conversation

@Khamel83

@Khamel83 Khamel83 commented Jun 6, 2026

Copy link
Copy Markdown
Owner

Summary

Brief description of what this PR does and why.

Type of change

  • Bug fix
  • New feature
  • Refactor / cleanup
  • Docs only
  • Build / CI / tooling

Changes

Testing

  • uv run pytest tests/ -v --tb=short passes locally
  • Manually verified with:

Checklist

  • Code follows existing patterns
  • New features have tests
  • Docs updated where user-facing behavior changed
  • No breaking change to the public API (or noted below if there is)

Breaking change?

If this is a breaking change, describe the impact and the migration path here.

Khamel83 added 2 commits June 2, 2026 23:56
Cookie tokens for paywall site extraction could expire without any warning:
- load_editthiscookie_json() silently filtered expired cookies with no log,
  returning empty lists when all cookies expired
- extract_authenticated() returned None when contexts failed, causing
  track_attempt to crash with AttributeError
- The crash was caught by a bare except and logged at DEBUG level,
  making it invisible in production

Now expired cookies are counted and warned about, auth failures return
proper ExtractedContent with error messages, track_attempt handles
None defensively, and auth exceptions are logged at WARNING level.

Resolves #58
@Khamel83

Khamel83 commented Jun 6, 2026

Copy link
Copy Markdown
Owner Author

Confidence: 58/100

Fix addresses silent cookie expiration with logging and error returns, but lacks tests and includes an unrelated new search-and-summarize endpoint without test coverage.

If reviewing:

  • Verify auth_extractor changes don't break fallback logic
  • Add tests for cookie expiration handling
  • Add tests for search-and-summarize workflow

Reviewed by gateway/cheap — independent of worker agent

@Khamel83 Khamel83 merged commit 8898c07 into main Jun 6, 2026
4 checks passed
@Khamel83 Khamel83 deleted the fix/issue-58-auth-tokens-expire-silently branch June 6, 2026 00:52
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