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

Store and handle more user attributes #871

Merged
merged 32 commits into from
Apr 28, 2024
Merged

Store and handle more user attributes #871

merged 32 commits into from
Apr 28, 2024

Conversation

henrikskog
Copy link
Contributor

@henrikskog henrikskog commented Apr 12, 2024

  • Stores all user attributes and not just email and studyYear
  • Removes user fixtures because they are outdated and of little value now that users are stored in auth0
  • Removes user dashboard page as this is recreated in next PR to avoid having 1 million changes in this PR

For how user data is stored in auth0 (some properties are stored in app_metadata and some in user_metadata, see:

async update(sub: string, write: UserWrite) {

I have added a function that inserts fake data for the new fields until we gather this on signup such that we can maintain the not-null integrity of these fields thorughout the backend. See

await core.syncedUserService.handlePopulateUserWithFakeData(token.sub, token.email) // Remove when we have real data

@henrikskog henrikskog changed the base branch from main to fix/attendance-merge-race-condition April 12, 2024 19:07
@henrikskog henrikskog changed the title user attributes User Attributes Issue 2: Fake user attributes and implement handling of user with all attributes Apr 12, 2024
@henrikskog henrikskog force-pushed the fix/attendance-merge-race-condition branch 2 times, most recently from 9d8fac3 to cedde34 Compare April 14, 2024 14:17
@@ -249,7 +248,6 @@ export const createServiceLayer = async ({ db }: ServerLayerOptions) => {
attendeeService,
interestGroupRepository,
Copy link
Member

Choose a reason for hiding this comment

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

unrelated but this should probably not be here (cc @Terbau)

packages/core/src/modules/external/auth0-repository.ts Outdated Show resolved Hide resolved
@henrikskog henrikskog changed the title User Attributes Issue 2: Create CRUD for all user attributes synced between auth0 and local db Store and handle domain user attributes Apr 28, 2024
@henrikskog henrikskog changed the title Store and handle domain user attributes Store and handle more user attributes Apr 28, 2024
@henrikskog henrikskog enabled auto-merge (squash) April 28, 2024 10:56
@henrikskog henrikskog merged commit 4133181 into main Apr 28, 2024
4 of 7 checks passed
@henrikskog henrikskog deleted the user-attributes branch April 28, 2024 10:57
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