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

Respond with 4xx not 5xx to badly formulated URLs #50

Open
nicholascar opened this issue Apr 27, 2021 · 0 comments
Open

Respond with 4xx not 5xx to badly formulated URLs #50

nicholascar opened this issue Apr 27, 2021 · 0 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@nicholascar
Copy link
Member

A bot-generated URL like this:

https://linked.data.gov.au/def/geological-observation-type/radiometric%22,%22observationDate%22:%221990-05-31T14:00:00Z%22,%22AirSurvConfigNo_description%22:%22%22,%22partyRole

results in a redirect to VP like this:

https://vocabs.gsq.digital/object?vocab_id=geological-observation-type&uri=http://linked.data.gov.au/def/geological-observation-type/radiometric%22,%22observationDate%22:%221990-05-31T14:00:00Z%22,%22AirSurvConfigNo_description%22:%22%22,%22partyRole

All VP instances (1.x & 2.x) respond similarly, e.g. the DAWE instance:

http://dawe.surroundaustralia.com/object?vocab_id=geological-observation-type&uri=http://linked.data.gov.au/def/geological-observation-type/radiometric%22,%22observationDate%22:%221990-05-31T14:00:00Z%22,%22AirSurvConfigNo_description%22:%22%22,%22partyRole

VP then returns a 500, but it should return 4xx (likely 400), so a code change is needed to validate the Query String Args before querying the DB to prevent a 500 fail.

@nicholascar nicholascar added the bug Something isn't working label Apr 27, 2021
@nicholascar nicholascar added this to the VP-2.5.9 milestone Apr 27, 2021
@nicholascar nicholascar self-assigned this Apr 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant