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

How to document endpoints blocking certain user-agents? #54

Open
1Maxnet1 opened this issue Aug 15, 2022 · 1 comment
Open

How to document endpoints blocking certain user-agents? #54

1Maxnet1 opened this issue Aug 15, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@1Maxnet1
Copy link
Collaborator

In #53 I discovered that the bwegt-trias-endpoint blocks certain user-agent headers, as described here: https://python.tutorialink.com/post-request-to-trias-api-does-not-work-with-requests/

This seems to be a very weird issue and is rarely documented anywhere. However it would might make sense to document it in the .json as well, as else the requests will fail with 502 Error code, with no obvious reason. @derhuerst mentioned a similar issue in his comment I contacted a contact at nvbw regarding this issue and will update the issue when I get an answer. The solution for me was just to set the user-agent manually to a working string.

Some naive possibilities how to document the blocked user-agents:

  • List all/some known working user-agents: This list will never be complete and can be exhausting, also usually the User-agent is used to identify a client. Manipulating it, does not make to much semantic sense and in my opinion (imo.) is rather a workaround then a fix.
  • List all/some known to be blocked/broken user-agents: This would be never complete as well, but could be an easier list as people who trigger the problem could look up the list and check their clients user-agent and implement a workaround or contact upstream to fix it on the endpoint side. Personally I would prefer the second option.
  • Instead of listing the known/broken user-agents we could document them in a markdown file as examples and give the users of this repository a starting point. This list would not need to be exhausting, but also couldn't be utilized by clients.
  • We could also keep this issue rather general and start in a markdown file / the GitHub wiki a list of common technical issues and how to prevent them. This imo. would be such an issue. Especially if further similar issues exist, this would be an easy way to deal with the issue.

If anyone has any thoughts on that, or did encounter this issue as well, I would appreciate some opinions :)

@derhuerst derhuerst added the enhancement New feature or request label Aug 15, 2022
@1Maxnet1
Copy link
Collaborator Author

1Maxnet1 commented Oct 7, 2022

I just raised the issue in the newly created discussion space of Mobidata-BW: mobidata-bw/TRIAS#5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

No branches or pull requests

2 participants