-
Notifications
You must be signed in to change notification settings - Fork 515
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
patch for #2781: User Agent header in doc loader #2824
patch for #2781: User Agent header in doc loader #2824
Conversation
Signed-off-by: George Mulhearn <[email protected]>
hmmm, getting a pipeline failure; i dont know acapy CI enough to know if this normal... |
Trying to re-run. Integration tests have been getting sporadic fails when there's multiple concurrent runs. |
Quality Gate passedIssues Measures |
@@ -122,6 +123,7 @@ def download(self, url: str, options: Optional[Dict], **kwargs): | |||
headers = options.get("headers") | |||
if headers is None: | |||
headers = {"Accept": "application/ld+json, application/json"} | |||
headers["User-Agent"] = f"AriesCloudAgent/{__version__}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pending more discussion in #2781
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm thinking this is probably "good enough" to merge; future discussion can yield additional PRs but this will solve the immediate issue. I'd like to open another issue to capture the desire to apply User-Agent
headers wherever we make outbound requests (probably just webhooks and message delivery?). I believe the integration test failure is unrelated (though a sanity check from @jamshale would be appreciated). I'm willing to merge with that one failing test.
a patch for #2781 (see issue description). Longer term acapy may consider making a User Agent header globally for all requests, and perhaps configurable. however this one gets us by