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

cogito: properly encode url #153

Merged
merged 3 commits into from
Mar 26, 2024
Merged

cogito: properly encode url #153

merged 3 commits into from
Mar 26, 2024

Conversation

aliculPix4D
Copy link
Contributor

@aliculPix4D aliculPix4D commented Mar 22, 2024

cogito: properly encode url

Actually, the only problem that existed was due the way spaces were encoded. Even the most complex case with nested json worked fine with the existing code. The only thing "missing" was the proper encoding of spaces.

Concourse requires that the space characters are encoded as %20 instead of +. On the other hand golangs url.QueryEscape as well as url.Values.Encode() both encode the space as a + character.
See: golang/go#4013

Fixes: #148

@aliculPix4D
Copy link
Contributor Author

See:
Screenshot from 2024-03-22 10-55-58

the link for autocat (from my local concourse deployment) correctly points to the build. The pipeline was worst case scenario possible: nested json with spaces

Sadly, we can't test this better in our Concourse deployment because we don't have CONCOURSE_ENABLE_PIPELINE_INSTANCES enabled.

@aliculPix4D aliculPix4D merged commit fd7191d into master Mar 26, 2024
2 checks passed
@aliculPix4D aliculPix4D deleted the pci-3688-cogito-encode-url branch March 26, 2024 13:58
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.

Build links for instanced pipelines don't work
6 participants