Skip to content

Conversation

@diox
Copy link
Member

@diox diox commented Jun 13, 2025

Fixes mozilla/addons#15620

Testing

  • Follow instructions in Parse and store data collection permissions, behind a waffle switch #23545 to upload an add-on with data collection permissions, but make sure to submit it as listed
  • Approve that add-on
  • Look at its detail API (http://olympia.test/api/v5/addons/addon/<pk_or_slug_or_guid>/) and search API (http://olympia.test/api/v5/addons/search/?guid=<guid>) and check data_collection_permissions and optional_data_collection_permissions are there and correct

Bonus:

  • Check search API still works for other add-ons you already had (the 2 data collection properties should be an empty array)

@diox diox marked this pull request as ready for review June 13, 2025 12:40
@diox diox requested review from a team and eviljeff and removed request for a team June 13, 2025 12:40
data_collection_permissions = serializers.ListField(child=serializers.CharField())
optional_data_collection_permissions = serializers.ListField(
child=serializers.CharField()
)
Copy link
Member

Choose a reason for hiding this comment

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

I know it doesn't matter a great deal... But these extra properties should be behind an API gate

Copy link
Member Author

Choose a reason for hiding this comment

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

Should they ? It's just new properties so I don't really care. We didn't bother when we added host_permissions.

@diox diox merged commit d0a32e1 into mozilla:master Jun 16, 2025
42 checks 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.

[Task]: Add support for data collection permissions in the HTTP API

2 participants