-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
feat(ee): add name
field for user model, add api to update it
#2100
Conversation
autofix failed due to
cargo_bloat failed due to
Test coverage failed due to:
All of errors seem irrelevant to my change |
0fffece
to
9e25b9e
Compare
code coverage report |
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.
Otherwise LGTM.
As a followup, please fill user.name field when user registered from oauth identity providers.
Correct me if I'm wrong, currently when user register from oauth, we only fetch user email info then create user accordingly. One more concern is, in this PR I didn't put |
a00df51
to
1b717e1
Compare
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.
Otherwise LGTM
ee/tabby-schema/src/schema/auth.rs
Outdated
#[validate(regex( | ||
code = "username", | ||
path = "crate::schema::constants::USERNAME_REGEX", | ||
message = "Invalid username, only alphabet and space character are allowed, and it must start and end with alphabet" |
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.
message = "Invalid username, only alphabet and space character are allowed, and it must start and end with alphabet" | |
message = "Invalid name, only alphabet and space character are allowed, and it must start and end with alphabet" |
Is non-english characters, e.j german / chinese valid name with this regex?
Please also rebase against main |
1b717e1
to
115e8fb
Compare
09a1f29
to
f5f05f9
Compare
For closing #2054
add new migration to alter
users
tablename
could beNULL
for back compatibilityupdate
UserDAO
to addname
field, addupdate_user_name
to executeSQL UPDATE
implement new endpoint
update_user_name
forAuthenticationService
implement new mutation endpoint
update_user_name
run
make update-db-schema
to updateee/tabby-db/schema/schema.sql
&ee/tabby-db/schema/schema.svg
run
tabby-schema/examples/update-schema.rs
to updateschema.graphql
fileudpate
README