Skip to content

feat(download): adds auth to support new teehr-hub requirement#781

Merged
mgdenno merged 2 commits into
mainfrom
mdenno/780-update-download-to-include-auth
May 13, 2026
Merged

feat(download): adds auth to support new teehr-hub requirement#781
mgdenno merged 2 commits into
mainfrom
mdenno/780-update-download-to-include-auth

Conversation

@mgdenno

@mgdenno mgdenno commented May 13, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@mgdenno mgdenno linked an issue May 13, 2026 that may be closed by this pull request
@mgdenno
mgdenno requested review from Copilot and samlamont May 13, 2026 13:45

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the Download client to support teehr-hub’s new authentication requirements (API key / bearer token) and adjusts pagination behavior to follow server-provided links (rel=next) when available. It also adds opt-in local integration testing guidance and markers.

Changes:

  • Add api_key / bearer_token configuration and send auth headers on outbound download requests.
  • Update pagination to prefer links[rel=next] URLs and allow omitting limit when page_size=None.
  • Add local_api pytest marker plus README guidance and new unit/integration tests covering auth + pagination.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
src/teehr/evaluation/download.py Adds auth header support and next-link pagination logic; updates page sizing defaults to allow server-controlled limits.
tests/download/test_download.py Adds local_api-marked integration tests and new unit tests for auth headers + pagination behavior.
tests/README.md Documents how to run opt-in local teehr-hub integration tests and required env vars/markers.
pytest.ini Registers the new local_api marker.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/teehr/evaluation/download.py Outdated
Comment thread src/teehr/evaluation/download.py Outdated
Comment thread tests/download/test_download.py
@mgdenno

mgdenno commented May 13, 2026

Copy link
Copy Markdown
Contributor Author

@samlamont I addressed copilot comments. I think it is pretty good.

@mgdenno
mgdenno merged commit f73982f into main May 13, 2026
@mgdenno
mgdenno deleted the mdenno/780-update-download-to-include-auth branch May 13, 2026 19:59
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.

update download to include auth

3 participants