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

Do not retry 400 and print better error messages #5326

Merged
merged 1 commit into from Jun 10, 2019

Conversation

Projects
None yet
2 participants
@lasote
Copy link
Contributor

commented Jun 10, 2019

Changelog: Bugfix: Conan was retrying the upload when failed with error 400 (request error).
Changelog: Feature: Print nicer error messages when receive an error from Artifactory.
Docs: omit

Raised by Artifactory QA team, when trying to upload to a virtual repository (without configured deploy repo) we were retrying and not printing anymore the server error in the output:

At 1.15:

Error uploading file: conanfile.py, 'b'{\n  "errors" : [ {\n    "status" : 400,\n    "message" : "Unable to upload into a virtual Conan repository without default local deployment repository configured."\n  } ]\n}''

At 1.16:

Error uploading file: conanfile.py, '400 Client Error: Bad Request for url: http://artifactory:8081/artifactory/api/conan/conan-virtual/v2/conans/simple/1.0/user/channel/revisions/a20a0ec96d592dd6e90448b311856074/files/conanfile.py

From now on:

Error uploading file: conanfile.py, '400: Unable to upload into a virtual Conan repository without default local deployment repository configured.'

@lasote lasote added this to the 1.16.1 milestone Jun 10, 2019

@lasote lasote requested a review from memsharded Jun 10, 2019

output.writeln("")
if not response.ok:

This comment has been minimized.

Copy link
@lasote

lasote Jun 10, 2019

Author Contributor

This code shouldn't be reached anymore.

self._output.writeln("")
if not response.ok:

This comment has been minimized.

Copy link
@lasote

lasote Jun 10, 2019

Author Contributor

This code shouldn't be reached anymore.

@memsharded
Copy link
Contributor

left a comment

Much better, indeed

@memsharded memsharded merged commit 1eca20b into conan-io:release/1.16.1 Jun 10, 2019

2 checks passed

continuous-integration/jenkins/pr-head This commit looks good
Details
license/cla Contributor License Agreement is signed.
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.