-
Notifications
You must be signed in to change notification settings - Fork 29
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
Redundant Object Key Slashes Preventing Resolution #52
Comments
Should I move this to ohnosequences/ivy-s3-resolver? |
|
@michaelahlers Thanks for reporting and debugging. Are you sure v0.16.0 worked with your repository? Because I didn't touch any code related to this.
It's a good idea. I'm pretty sure S3 paths can't contain double slash. I still don't understand though where it comes from. I will take a closer look tonight. |
@laughedelic, it may be a problem with SBT. Forgot to mention this with 1.0.2, which may have changed the resolver's behavior (updated my earlier comment to mention the Ivy version in use). |
Publishing |
This is correct! 🎯 I just published (locally) v0.17.0 for sbt-0.13, tried to publish and it went fine. But with sbt-1.0+ it publishes (and resolves) with that extra slash. On another note, I discovered that S3 treats this extra slash as a separate object. So if you have
The it will publish it to
Which is complete nonsense if you ask me. But this is how S3 works. Anyway, thanks for noticing this and fixing 👍 I'm going to merge your workaround and cut a hotfix release. |
It's a bit funny; a coworker and I noticed that publishing with that redundant delimiter does work and—because S3 is a key-value store with no concept of paths—it accepts it and the UI conveniently presents it as an empty segment. Doh! Cool we nailed this one fast. Looking forward to that new version! |
Are you sure about this? I tried it out and I still observe the problem. I think that it doesn't change the behaviour of publishing anyway, plus for resolving, I think malformed URI is still passed to the Before patching all things in ivy-s3-resolver, I'd like to figure out where does this malformed URI come from originally (and why it changed in sbt-1.0) and probably then we can fix this better. |
OK. I found where is the problem. As far I understand in sbt-1.0 they started using sbt/librarymanagement. And there they changed
Besides that there are some new segments, there is this extra
|
With 0.17.0 (I think; haven't seen this with 0.16.0), S3 object keys contain an extra slash that prevents resolution.
Log messages like the following appear:
For S3, these are not normalized. The CLI, for example, produces different results:
SBT
build.properties
:Plugin added with:
Resolver defined as:
(Logs truncated and specifics redacted as appropriate.)
The text was updated successfully, but these errors were encountered: