Repository navigation
feat(azure): change member IDs and choose the new member's address #95
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
Draft
viganogabriele
wants to merge
5
commits into
main
Choose a base branch
from
feat/azure-member-number
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
2b077c5
feat(azure): change member IDs and choose the new member's address
viganogabriele d00f422
fix(azure): retain saved member IDs and report welcome email failures
viganogabriele 89a64fa
chore: merge current UI polish into member workflow branch
viganogabriele 4f6de0a
docs(azure): refresh screenshots after the main UI update
viganogabriele e71964f
fix(azure): validate optional notification status
viganogabriele File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| /** Mirrors the backend's `src/azure/mailbox.ts`, which builds and checks the address again. */ | ||
| export const MAIL_DOMAIN = "polinetwork.org" | ||
|
|
||
| const LOCAL_PART = /^[a-z0-9]+(?:[.-][a-z0-9]+)*$/ | ||
|
|
||
| export type MailboxKind = "standard" | "custom" | ||
|
|
||
| export function isLocalPart(value: string) { | ||
| return value.length <= 64 && LOCAL_PART.test(value) | ||
| } | ||
|
|
||
| /** Accents and apostrophes are dropped and spaces removed: "Niccolò", "D'Amico" -> "niccolo.damico". */ | ||
| function namePart(name: string) { | ||
| return name.trim().normalize("NFD").replace(/\p{M}/gu, "").replace(/['\s]/g, "").toLowerCase() | ||
| } | ||
|
|
||
| /** `firstname.lastname`, or null when the name has letters an address cannot hold (e.g. "Łukasz"). */ | ||
| export function standardLocalPart(firstName: string, lastName: string): string | null { | ||
| const localPart = `${namePart(firstName)}.${namePart(lastName)}` | ||
| return isLocalPart(localPart) ? localPart : null | ||
| } | ||
|
|
||
| export function isPoliNetworkAddress(email: string) { | ||
| return email.trim().toLowerCase().endsWith(`@${MAIL_DOMAIN}`) | ||
| } |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
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.
🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift
Update
@polinetwork/backendto the release whosesetAssocNumberreturnsnotificationSent. The installed backend types return only{ error: string | null }, sopnpm typecheckfails with TS2339.src/features/azure/azure.functions.ts#L34-L48: bump the backend dependency so the handler's return type includesnotificationSent. Do not cast the result.src/features/azure/member-number-dialog.tsx#L87-L87: no code change is needed. Confirm that typecheck passes after the bump.📍 Affects 2 files
src/features/azure/azure.functions.ts#L34-L48(this comment)src/features/azure/member-number-dialog.tsx#L87-L87🤖 Prompt for AI Agents
Source: Pipeline failures
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.
Giusto, è il motivo per cui la PR è in draft. Il tipo con
notificationSentarriva con PoliNetworkOrg/backend#70: appena viene pubblicato il nuovo@polinetwork/backendaggiorno la dipendenza qui, senza cast. In locale, con i tipi generati da quel branch,pnpm typecheckpassa.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.
@viganogabrielegrazie per il chiarimento. È una dipendenza prevista della PR in draft, non una modifica necessaria al dialog. Il risultato locale con i tipi di PoliNetworkOrg/backend#70 è coerente con questa spiegazione. Il finding resta aperto in attesa del rilascio e dell’aggiornamento della dipendenza, senza cast.You are interacting with an AI system.