Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

refactor: replace Code by Detail in the http API error#1011

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
BrunoQuaresma merged 5 commits intomainfrombq/1008/replace-code-by-detail
Apr 18, 2022

Conversation

BrunoQuaresma
Copy link
Collaborator

Closes#1008

@BrunoQuaresma
Copy link
CollaboratorAuthor

Should we create a function to centralize these messages?

@codecov
Copy link

codecovbot commentedApr 14, 2022
edited
Loading

Codecov Report

Merging#1011 (35f9f18) intomain (76f8ff9) willincrease coverage by0.02%.
The diff coverage is93.33%.

@@            Coverage Diff             @@##             main    #1011      +/-   ##==========================================+ Coverage   67.08%   67.10%   +0.02%==========================================  Files         256      256                Lines       14986    14986                Branches      136      136              ==========================================+ Hits        10053    10056       +3+ Misses       3938     3935       -3  Partials      995      995
FlagCoverage Δ
unittest-go-macos-latest53.57% <93.33%> (-0.14%)⬇️
unittest-go-postgres-66.76% <93.33%> (+0.05%)⬆️
unittest-go-ubuntu-latest56.12% <93.33%> (-0.21%)⬇️
unittest-go-windows-202253.03% <93.33%> (+0.02%)⬆️
unittest-js62.94% <ø> (ø)
Impacted FilesCoverage Δ
codersdk/client.go59.74% <0.00%> (ø)
coderd/httpapi/httpapi.go72.50% <100.00%> (ø)
coderd/organizations.go60.64% <100.00%> (ø)
coderd/users.go59.60% <100.00%> (ø)
coderd/workspaces.go55.62% <100.00%> (ø)
coderd/parameter/compute.go74.07% <0.00%> (-6.67%)⬇️
provisionerd/provisionerd.go82.35% <0.00%> (-0.45%)⬇️
coderd/database/queries.sql.go83.65% <0.00%> (-0.42%)⬇️
coderd/provisionerdaemons.go63.97% <0.00%> (+0.51%)⬆️
peer/conn.go82.23% <0.00%> (+1.77%)⬆️
... and3 more

Continue to review full report at Codecov.

Legend -Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing data
Powered byCodecov. Last update76f8ff9...35f9f18. Read thecomment docs.

BrunoQuaresmaand others added3 commitsApril 14, 2022 16:35
Co-authored-by: G r e y <grey@coder.com>
Copy link
Contributor

@greyscaledgreyscaled left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

This looks good to me, but we should get approval from @coder/backend

@greyscaledgreyscaled requested a review froma teamApril 15, 2022 19:01
Copy link
Member

@johnstcnjohnstcn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

As far as I know, the idea of theCode field is to allow a machine-readable error message.
Should we maybe keep bothCode andDetail fields instead?

@kylecarbs
Copy link
Member

The idea short-term is to try eliminating machine-readable messages in favor of HTTP response codes. If that doesn't work, we'll probably have to do something like that.

@BrunoQuaresmaBrunoQuaresma merged commit3311c2f intomainApr 18, 2022
@BrunoQuaresmaBrunoQuaresma deleted the bq/1008/replace-code-by-detail branchApril 18, 2022 16:02
@missknissmisskniss added this to theV2 Beta milestoneMay 15, 2022
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@johnstcnjohnstcnjohnstcn approved these changes

@kylecarbskylecarbskylecarbs approved these changes

@greyscaledgreyscaledgreyscaled approved these changes

Assignees

@BrunoQuaresmaBrunoQuaresma

Labels
None yet
Projects
None yet
Milestone
V2 Beta
Development

Successfully merging this pull request may close these issues.

Refactor: Exchange code for detail in API Error Responses
5 participants
@BrunoQuaresma@kylecarbs@johnstcn@greyscaled@misskniss

[8]ページ先頭

©2009-2025 Movatter.jp