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

chore: update v1 schema#643

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
coadler merged 3 commits intomainfromcolin/uuid-schema
Apr 1, 2022
Merged

chore: update v1 schema#643

coadler merged 3 commits intomainfromcolin/uuid-schema
Apr 1, 2022

Conversation

coadler
Copy link
Contributor

@coadlercoadler commentedMar 29, 2022
edited
Loading

Now uses UUIDs for users, organizations, organization members, and api keys. Also updates the v1 migration to correctly create indexes and foreign keys that were missed previously.

@coadlercoadler self-assigned thisMar 29, 2022
@codecov
Copy link

codecovbot commentedMar 29, 2022
edited
Loading

Codecov Report

Merging#643 (da23bf5) intomain (efec029) willincrease coverage by1.99%.
The diff coverage is80.21%.

@@            Coverage Diff             @@##             main     #643      +/-   ##==========================================+ Coverage   62.07%   64.06%   +1.99%==========================================  Files         113      199      +86       Lines       10755    11861    +1106       Branches        0       87      +87     ==========================================+ Hits         6676     7599     +923- Misses       3296     3439     +143- Partials      783      823      +40
FlagCoverage Δ
unittest-go-63.04% <80.21%> (?)
unittest-go-macos-latest59.00% <80.21%> (+0.15%)⬆️
unittest-go-ubuntu-latest61.76% <80.21%> (-0.06%)⬇️
unittest-go-windows-202258.02% <79.67%> (?)
unittest-js62.63% <ø> (?)
Impacted FilesCoverage Δ
cli/parameters.go16.07% <0.00%> (-0.30%)⬇️
cli/workspacedelete.go17.64% <0.00%> (ø)
cli/workspacelist.go9.52% <0.00%> (ø)
cli/workspaces.go51.61% <0.00%> (ø)
cli/workspaceshow.go14.28% <0.00%> (ø)
cli/workspacestart.go15.15% <0.00%> (ø)
cli/workspacestop.go13.88% <0.00%> (ø)
cli/workspaceupdate.go7.89% <0.00%> (ø)
codersdk/projects.go60.37% <ø> (ø)
codersdk/workspacebuilds.go58.33% <ø> (ø)
... and129 more

Continue to review full report at Codecov.

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

@coadlercoadlerforce-pushed thecolin/uuid-schema branch 4 times, most recently from0f51d90 tobd149b1CompareMarch 30, 2022 22:31
@coadlercoadler marked this pull request as ready for reviewMarch 30, 2022 22:45
@coadlercoadler requested a review fromkylecarbsMarch 30, 2022 22:45
Copy link
Member

@kylecarbskylecarbs left a comment

Choose a reason for hiding this comment

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

Let's trim down the initial migration as much as we possibly can. The initial schema should be 90% v2, and justsupporting v1 in a very soft way.

httpapi.Write(rw, http.StatusNotFound, httpapi.Response{
Message: fmt.Sprintf("organization %q does not exist", organizationID),
})
orgID, ok := parseUUID(rw, r, "organization")
Copy link
Member

Choose a reason for hiding this comment

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

Why abbreviate here and not fororganization? We should be consistent with abbreviations.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

I don't think it's necessarily important for local variables,organization is a lot to type every time. IMO it's only important for exported variables and function params.

Copy link
Member

Choose a reason for hiding this comment

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

That's a bit of an arbitrarily drawn line though. It's more to type, but an inconsistent naming scheme hurts readability.

@@ -46,31 +47,37 @@ func List() ([]Example, error) {
returnError = xerrors.Errorf("example %q does not contain README.md", exampleID)
return
}

Copy link
Member

Choose a reason for hiding this comment

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

I'd rather add a linting rule to enforce newline conventions. Arbitrarily doing it on a per-developer basis will read to inconsistency when reading our code.

@coadlercoadlerforce-pushed thecolin/uuid-schema branch 5 times, most recently from9a63ac3 to2a61e73CompareMarch 31, 2022 18:22
@coadlercoadler requested a review fromkylecarbsMarch 31, 2022 18:26
Copy link
Member

@kylecarbskylecarbs left a comment

Choose a reason for hiding this comment

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

Good changes! One minor nit, but that's all.

Comment on lines 21 to 22
revoked boolean NOT NULL,
login_type login_type NOT NULL,
Copy link
Member

Choose a reason for hiding this comment

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

These could be removed too!

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

This is referenced a bunch in the code, I'd rather remove these after.

@coadlercoadler merged commit2b1a0ee intomainApr 1, 2022
@coadlercoadler deleted the colin/uuid-schema branchApril 1, 2022 19:42
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@kylecarbskylecarbskylecarbs approved these changes

Assignees

@coadlercoadler

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@coadler@kylecarbs

[8]ページ先頭

©2009-2025 Movatter.jp