-
-
Notifications
You must be signed in to change notification settings - Fork 227
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
download / registry requests silently fail #1104
Conversation
- making errors like 'unknown package' actually understandable
- making errors like 'unknown package' actually understandable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There many occurrences of |
Seems to require a bit more work https://travis-ci.org/dlang/dub/jobs/216294639#L724 |
I am observing "X references unknown package Y" very often on AppVeyor, e.g.
Hmm I see:
But this function is properly defined here: https://github.com/dlang/dub/blob/stable/test/issue616-describe-vs-generate-commands.sh (I tried restarting Travis) |
- making errors like 'unknown package' actually understandable
Thanks for your pull request, @MartinNowak! |
/++ | ||
Exception thrown on HTTP request failures, e.g. 404 Not Found. | ||
+/ | ||
static if (__VERSION__ <= 2075) class HTTPStatusException : CurlException |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will there be a HTTPStatusException
in 2.076.0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes dlang/phobos#5551.
Have you tried to use this with a second (empty) registry? I didn't go through the individual errors in detail, but it could very well be that this could lead to lots of bogus error messages when a package exists in one registry but not in another. |
Looks OK to me. |
- making errors like 'unknown package' or 'no package found' actually understandable
I've changed this to only handle 404's in getMetadata, everything else relies on that method and checks for a null JSON as return value. |
b6907f7
to
5c451fd
Compare
LGTM, but it should be retargeted to master to get some room for testing. |
- making errors like 'unknown package' or 'no package found' actually understandable
- and throw any other errors - also see dlang/phobos#5551 for HTTPStatusException
Done |
@MartinNowak if you have mange access here (BTW, would sometimes be useful if I had), you'll have to override the merge due to the dmd-beta failure. |
Restarted with the latest DMD beta. |
Took me an extra hour of debugging why our builds fails ;).
At least for search the exception that libcurl couldn't be loaded is silently ignored,
dub/source/dub/packagesupplier.d
Line 229 in 7562402
Root package assert_writeln_magic references unknown package libdparse
with no further indication of the underlying problem.Based on v1.1.0, but still seems to be present.