Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Data Request script to compute requesting issuer and have configurable depth #11541

Merged

Conversation

mitchellhenke
Copy link
Contributor

🛠 Summary of changes

Following discussion yesterday here, this PR tries to address two potential improvements in the data request script:

  1. Looking up the service provider issuer automatically when the script is supplied without a requesting issuer, but is given ServiceProviderIdentity/AgencyIdentity UUIDs
  2. Configurable depth (defaulting to 0)

…igurable depth

changelog: Internal, Scripts, Update DataRequest script to compute requesting issuer and have configurable depth
@mitchellhenke mitchellhenke force-pushed the mitchellhenke/compute-requesting-issuer-in-data-request branch from 0a125b4 to 256b4e9 Compare November 21, 2024 16:27
return nil if service_providers.empty?
service_provider = service_providers.tally.max_by { |_sp, count| count }[0]

warn "Computed service provider #{service_provider}"
Copy link
Member

@matthinz matthinz Nov 21, 2024

Choose a reason for hiding this comment

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

Maybe warn if there were UUIDs from multiple SPs detected?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done!

Copy link
Member

@matthinz matthinz left a comment

Choose a reason for hiding this comment

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

This is great. Thank you!

lib/data_pull.rb Outdated Show resolved Hide resolved
lib/data_pull.rb Outdated Show resolved Hide resolved
mitchellhenke and others added 2 commits November 22, 2024 15:56
Co-authored-by: Zach Margolis <[email protected]>
Co-authored-by: Zach Margolis <[email protected]>
@mitchellhenke mitchellhenke merged commit 0aa1128 into main Nov 25, 2024
2 checks passed
@mitchellhenke mitchellhenke deleted the mitchellhenke/compute-requesting-issuer-in-data-request branch November 25, 2024 15:10
AShukla-GSA pushed a commit that referenced this pull request Nov 25, 2024
…igurable depth (#11541)

* Update Data Request script to compute requesting issuer and have configurable depth

changelog: Internal, Scripts, Update DataRequest script to compute requesting issuer and have configurable depth

* add log for multiple service providers

* Update lib/data_pull.rb

Co-authored-by: Zach Margolis <[email protected]>

* Update lib/data_pull.rb

Co-authored-by: Zach Margolis <[email protected]>

---------

Co-authored-by: Zach Margolis <[email protected]>
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.

3 participants