Skip to content

Conversation

@heathdutton
Copy link

Fixes #6667

The Journalist API's /sources endpoint was returning sources that the Journalist Interface filters out. Specifically, sources with last_updated=None were included in API responses but excluded from the JI.

This adds the missing .filter(Source.last_updated.isnot(None)) to align the API with the Journalist Interface behavior.

Test plan

  1. Start the dev environment and create a source that has not yet submitted anything (so last_updated is null)
  2. Query /api/v1/sources - verify the incomplete source is not returned
  3. Submit something as that source
  4. Query /api/v1/sources again - verify the source now appears

Checklist

This change accounts for:

  • any required additional documentation
  • any necessary AppArmor changes (added or removed application files)
  • any impact on new SecureDrop installs and upgrades
  • our dependency update policy

@heathdutton heathdutton requested a review from a team as a code owner January 1, 2026 17:25
@zenmonkeykstop zenmonkeykstop moved this to Next sprint candidates in SecureDrop Jan 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Next sprint candidates

Development

Successfully merging this pull request may close these issues.

Journalist Interface and API return different subsets of Sources

1 participant