hydra
hydra copied to clipboard
Invalid snapshot filename breaks importing the Hydra packages
Preflight checklist
- [X] I could not find a solution in the existing issues, docs, nor discussions.
- [X] I agree to follow this project's Code of Conduct.
- [X] I have read and am following this repository's Contribution Guidelines.
- [ ] This issue affects my Ory Cloud project.
- [ ] I have joined the Ory Community Slack.
- [ ] I am signed up to the Ory Security Patch Newsletter.
Describe the bug
Hi,
I'm interested in the latest release (v1.11.9) to use RefreshTokenHook structs but it seems I cannot download it due to this error:
github.com/ory/hydra/oauth2: create zip: oauth2/.snapshots/TestAuthCodeWithMockStrategy-strategy=jwt-case=2-description=should_pass_because_prompt=none_and_max_age_<_auth_time-should_call_refresh_token_hook_if_configured.json: malformed file path "oauth2/.snapshots/TestAuthCodeWithMockStrategy-strategy=jwt-case=2-description=should_pass_because_prompt=none_and_max_age_<_auth_time-should_call_refresh_token_hook_if_configured.json": invalid char '<'
oauth2/.snapshots/TestAuthCodeWithMockStrategy-strategy=opaque-case=2-description=should_pass_because_prompt=none_and_max_age_<_auth_time-should_call_refresh_token_hook_if_configured.json: malformed file path "oauth2/.snapshots/TestAuthCodeWithMockStrategy-strategy=opaque-case=2-description=should_pass_because_prompt=none_and_max_age_<_auth_time-should_call_refresh_token_hook_if_configured.json": invalid char '<'
make: *** [deps] Error 1
Indeed, you have 1 snapshot file having in its name <... making the process broken:
https://github.com/ory/hydra/blob/master/oauth2/.snapshots/TestAuthCodeWithMockStrategy-strategy=jwt-case=2-description=should_pass_because_prompt=none_and_max_age_%3C_auth_time-should_call_refresh_token_hook_if_configured.json
Thank you,
cc @grantzvolsky @aeneasr
Reproducing the bug
Use an Hydra package in a Go project and go mod tidy
Relevant log output
No response
Relevant configuration
No response
Version
v1.11.7
On which operating system are you observing this issue?
macOS
In which environment are you deploying?
Other
Additional Context
No response
This should be resolved on v2.x already :)
@aeneasr but what if I want to stick to v1.x? Do you plan to release a v1.11.10 with corrected name?
There are no more releases planned for the v1 branch, the next release will be v2.0-beta.1 :)
Oh ok, that's sad because yesterday you released the v1.11.9 with new modifications on structs for the RefreshTokenHook but if it can't be imported at the end :( (I need them to decode webhook and encode response)
I can still try to copy/paste the structs tree for the ones needed, or fork without snapshots...
We can also cherry-pick https://github.com/ory/hydra/pull/2796/commits/e437e3ed60e49e245119ea43345403f8775122ad to master but we won't release it as the change is non-functional and importing this package is an edge case :)
You can probably also work around it by not using a go module proxy so basically GOPROXY=direct
I think cherry-picking would do the trick!
Thank you,