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

fix: return code in CompileAndPublish rather than handleError #1107

Merged
merged 5 commits into from
Apr 16, 2024

Conversation

ecrupper
Copy link
Contributor

It'll be easier to follow that CompileAndPublish errors are returned with a code to handle rather than handle them itself.

I also made all the responses match across create, restart, and PostWebhook:

  • 200 = skipped
  • 201 = created
  • 400 = bad request
  • 401 = unauthorized owner
  • 404 = missing resource
  • 429 = build limit reached
  • 500 = error processing or server unreachable

Open to suggestions on that, but the inconsistencies should be addressed at least.

@ecrupper ecrupper requested a review from a team as a code owner April 12, 2024 17:58
Copy link

codecov bot commented Apr 12, 2024

Codecov Report

Attention: Patch coverage is 0% with 27 lines in your changes are missing coverage. Please review.

Project coverage is 65.33%. Comparing base (04f9308) to head (aa0b87e).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1107      +/-   ##
==========================================
+ Coverage   65.22%   65.33%   +0.11%     
==========================================
  Files         371      371              
  Lines       11961    11940      -21     
==========================================
  Hits         7801     7801              
+ Misses       3657     3636      -21     
  Partials      503      503              
Files Coverage Δ
api/build/restart.go 0.00% <0.00%> (ø)
api/build/create.go 0.00% <0.00%> (ø)
api/build/compile_publish.go 0.00% <0.00%> (ø)

api/build/create.go Outdated Show resolved Hide resolved
@ecrupper ecrupper merged commit 7263f25 into main Apr 16, 2024
11 of 13 checks passed
@ecrupper ecrupper deleted the fix/compile-publish-error-handling branch April 16, 2024 14:40
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.

3 participants