Closed kavimuru closed 1 year ago
Triggered auto assignment to @laurenreidexpensify (Bug
), see https://stackoverflow.com/c/expensify/questions/14418 for more details.
Platforms
in OP are ✅)from @jayeshmangwani
Spanish character to room name shows the invalid name.
Here on the RoomNamePage page, we check the validity of the room name from the isValidRoomName function and
isValidRoomName check the valid room name with this regex;
https://github.com/Expensify/App/blob/ae8a751c04cd4b371bec1d976da204413b6bb4b9/src/CONST.js#L1135
above regex check the English character from a to z, but it does not allow Spanish character like é
We have to update the regex here like that it can accept all the valid Spanish characters; we need to add the new range for taking the Spanish characters à-ÿ
to ROOM_NAME regex.
https://github.com/Expensify/App/blob/ae8a751c04cd4b371bec1d976da204413b6bb4b9/src/CONST.js#L1135
ROOM_NAME: /^#[a-z0-9-]{1,80}$/,
ROOM_NAME: /^#[a-z0-9à-ÿ-]{1,80}$/,
Rather than adding the whole range of the alphabet, we can add only missing Spanish characters to the regex.
https://github.com/Expensify/App/blob/ae8a751c04cd4b371bec1d976da204413b6bb4b9/src/CONST.js#L1135
ROOM_NAME: /^#[a-z0-9-]{1,80}$/,
ROOM_NAME: /^#[a-z0-9-ñáéíóúü]{1,80}$/,
Accented Spanish characters are not permitted in room names.
The ValidationUtils.isValidRoomName method does not take into account accented Latin (including Spanish) characters.
Extend the regular expression defined in REGEX.ROOM_NAME (CONST.js) to include:
\u{00c0}-\u{024f}\u{1e00}-\u{1eff}
Which will allow accented Latin characters, including Spanish, to be added to room names.
Allowing Spanish characters specifically. However, this would be a hacky temporary solution as the broader problem is that accented Latin characters are currently disallowed, which for example also includes French accented characters.
📣 @samh-nl! 📣 Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork. Please follow these steps:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>
⚠️ Missing/invalid email or upwork profile link. Please make sure you add both your Expensify email and Upwork profile link in the format specified.
Contributor details Your Expensify account email: h.sam.lw@gmail.com Upwork Profile Link: https://upwork.com/freelancers/~016c982fe69f86aff8
Job added to Upwork: https://www.upwork.com/jobs/~01082e3b04cd3dad37
Current assignee @laurenreidexpensify is eligible for the External assigner, not assigning anyone new.
Triggered auto assignment to Contributor-plus team member for initial proposal review - @0xmiroslav (External
)
@0xmiroslav do any of the proposals above look good?
@0xmiroslav bump^^
@samh-nl can you please share the source link of that regex which supports Latin characters?
@0xmiroslav Do you have any feedback for my Proposal ?
@jayeshmangwani your proposal sounds good but checking to see if we can apply more general solution.
your proposal sounds good but checking to see if we can apply more general solution.
@0xmiroslav It will be applicable for all the Spanish characters, and We have a similar regex already in use, À-ÿ
in the below regex is used for Spanish small case and uppercase alphabets
https://github.com/Expensify/App/blob/8b7a65dcd36fa2b47ffb39c69f2cb294b94a7171/src/CONST.js#L1121
@jayeshmangwani ok great! As it's aligned with other name validation, it's fine to use à-ÿ
for now.
Before approving, can you please test all Spanish alphabets with this range?
@0xmiroslav Here is a regex tester with this regular expression, showing it's applicability: https://regex101.com/r/yvmwco/1 (multiline and global flags added for ease of reading)
It takes parts of Latin-1 Supplement, Latin Extended-A, Latin Extended-B and Latin Extended Additional.
The Spanish characters are contained within these standards, which I can validate manually.
@jayeshmangwani ok great! As it's aligned with other name validation, it's fine to use
à-ÿ
for now. Before approving, can you please test all Spanish alphabets with this range?
@0xmiroslav tested with all Spanish alphabets
I like @jayeshmangwani's proposal.
@samh-nl thanks for sharing links. For now, we're supporting only English and Spanish, a-zà-ÿ
should be enough to fix this issue and it's already aligned with legal name validation regex. We can always revisit all regexes when we support more languages in the future.
🎀 👀 🎀 C+ reviewed
Triggered auto assignment to @youssef-lr, see https://stackoverflow.com/c/expensify/questions/7972 for more details.
📣 @0xmiroslav You have been assigned to this job! Please apply to this job in Upwork here and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻 Once you apply to this job, your Upwork ID will be stored and you will be automatically hired for future jobs! Keep in mind: Code of Conduct | Contributing 📖
📣 @jayeshmangwani 🎉 An offer has been automatically sent to your Upwork account 🎉
Contributor - [$1000] Spanish character to room name shows the invalid name Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻 Keep in mind: Code of Conduct | Contributing 📖
📣 @jayeshmangwani 🎉 An offer has been automatically sent to your Upwork account 🎉
Reporter - [$1000] Spanish character to room name shows the invalid name
Sorry folks I broke the order here! Still waiting for @youssef-lr to sign off on the proposal https://github.com/Expensify/App/issues/21755#issuecomment-1618665262
Looks good to me @laurenreidexpensify!
📣 @0xmiroslav We're missing your Upwork ID to automatically send you an offer for the Reviewer role. Once you apply to the Upwork job, your Upwork ID will be stored and you will be automatically hired for future jobs!
📣 @jayeshmangwani 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!
Upwork job Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻 Keep in mind: Code of Conduct | Contributing 📖
📣 @jayeshmangwani 🎉 An offer has been automatically sent to your Upwork account for the Reporter role 🎉 Thanks for contributing to the Expensify app!
@0xmiroslav PR is ready for review,
@laurenreidexpensify I have accepted these 2 offers (https://github.com/Expensify/App/issues/21755#issuecomment-1619735243 , https://github.com/Expensify/App/issues/21755#issuecomment-1619735320) before, should I ignore these 2 offers (https://github.com/Expensify/App/issues/21755#issuecomment-1623616663 , https://github.com/Expensify/App/issues/21755#issuecomment-1623616773)?
@0xmiroslav bump for review
Reviewing
label has been removed, please complete the "BugZero Checklist".
The solution for this issue has been :rocket: deployed to production :rocket: in version 1.3.40-5 and is now subject to a 7-day regression period :calendar:. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2023-07-21. :confetti_ball:
After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
As a reminder, here are the bonuses/penalties that should be applied for any External issue:
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
@0xmiroslav can you complete the steps above? Thanks!
Waiting on @0xmiroslav for final steps here
Not overdue. Waiting for checklist.
Payment Summary:
We added Spanish validation in unit test so no further regression test step is needed.
This is eligible for timeline bonus
@laurenreidexpensify can you please hold my payment until further notice? I am working on some stuff due to recent measurements in my region. And update issue to Monthly. Thanks
Payment Summary Update:
@0xmiroslav can we pay this yet?
@laurenreidexpensify still in discussion. Thanks for your patience. This issue can be updated weekly
@laurenreidexpensify I have been paid for the reporter, but job is showing as Work in progress
at Upwork , Can you please End contract from your side at Upwork?
@jayeshmangwani ah sorry for confusion. I paid everything in one contract, have closed out the other contract now.
@0xmiroslav are we good to pay this one yet?
@laurenreidexpensify let's close this for now. I am tracking locally.
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
Expected Result:
We should not get the error of invalid Room name and the Spanish character should be a valid name
Actual Result:
Adding a Spanish character shows the error of an invalid room name
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.3.33-4 Reproducible in staging?: y Reproducible in production?: y If this was caught during regression testing, add the test name, ID and link from TestRail: Email or phone of affected tester (no customers): Logs: https://stackoverflow.com/c/expensify/questions/4856 Notes/Photos/Videos: Any additional supporting documentation
https://github.com/Expensify/App/assets/43996225/8c71790f-4fef-488f-9e78-86e7199cef24
https://github.com/Expensify/App/assets/43996225/46037323-60f2-4df2-aa3a-1e5eac96cae5
Expensify/Expensify Issue URL: Issue reported by: @jayeshmangwani Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1687765941593149
View all open jobs on GitHub
Upwork Automation - Do Not Edit