Skip to content

fix: published filter on get_feed by id#1401

Merged
davidgamez merged 1 commit intomainfrom
fix/published_filter
Oct 9, 2025
Merged

fix: published filter on get_feed by id#1401
davidgamez merged 1 commit intomainfrom
fix/published_filter

Conversation

@davidgamez
Copy link
Copy Markdown
Member

@davidgamez davidgamez commented Oct 9, 2025

Summary:

This pull request introduces a change to the GTFS feed retrieval logic to respect user email restrictions when querying for feeds. Now, the query will only return published feeds if the user has restricted email access.

Access control improvements:

  • Updated the _get_gtfs_feed method in feeds_api_impl.py to determine if only published feeds should be returned based on the result of is_user_email_restricted(), and passed this information to the get_gtfs_feeds_query function.

Expected behavior:

Internal users can get the non-published feeds

Testing tips:

Test in dev using https://mobility-feeds-dev--pr-1393-ncii6pry.web.app/feeds/mdb-742

Please make sure these boxes are checked before submitting your pull request - thanks!

  • Run the unit tests with ./scripts/api-tests.sh to make sure you didn't break anything
  • Add or update any needed documentation to the repo
  • Format the title like "feat: [new feature short description]". Title must follow the Conventional Commit Specification(https://www.conventionalcommits.org/en/v1.0.0/).
  • Linked all relevant issues
  • Include screenshot(s) showing how this pull request works and fixes the issue(s)

@davidgamez davidgamez marked this pull request as ready for review October 9, 2025 20:28
@davidgamez davidgamez merged commit 22f2c3a into main Oct 9, 2025
9 checks passed
@davidgamez davidgamez deleted the fix/published_filter branch October 9, 2025 20:33
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