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

[HOLD for payment 2024-03-25] [$500] [Wave Collect] [Categories] Categories - Not here page shows up when opening Parent/ and Parent/: Child category #37885

Closed
6 tasks done
kbecciv opened this issue Mar 7, 2024 · 33 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor

Comments

@kbecciv
Copy link

kbecciv commented Mar 7, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number: 1.4.48-0
Reproducible in staging?: y
Reproducible in production?: y
Issue reported by: Applause - Internal Team

Action Performed:

Precondition:

  • User is an admin of Collect workspace.
  1. Go to staging.new.expensify.com
  2. Go to Workspace settings > Collect workspace.
  3. Go to Categories.
  4. Click Add category.
  5. Add category in Parent/ and Parent/: Child format. And other special characters
  6. Click on the created category.

Expected Result:

Category RHP opens without issue.

Actual Result:

Not here page shows up when opening category with Parent/ and Parent/: Child style.

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6405006_1709792482718.20240307_141255.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01425421b068a188c5
  • Upwork Job ID: 1767873021149028352
  • Last Price Increase: 2024-03-13
@kbecciv kbecciv added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Mar 7, 2024
Copy link

melvin-bot bot commented Mar 7, 2024

Triggered auto assignment to @jliexpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@kbecciv
Copy link
Author

kbecciv commented Mar 7, 2024

We think that this bug might be related to #wave8-collect-admins
CC @zanyrenney

@kbecciv
Copy link
Author

kbecciv commented Mar 7, 2024

@jliexpensify I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors.

@tienifr
Copy link
Contributor

tienifr commented Mar 7, 2024

Proposal

Please re-state the problem that we are trying to solve in this issue.

Not here page shows up when opening category with Parent/ and Parent/: Child style.

What is the root cause of that problem?

We use encodeURI to encode the category name before passing it to route params:

getRoute: (policyID: string, categoryName: string) => `workspace/${policyID}/categories/${encodeURI(categoryName)}` as const,

However, encodeURI escapes all characters except /.

What changes do you think we should make in order to solve the problem?

Should use encodeURIComponent here and decodeURIComponent here as we've been using widely in App.

More info about the differences between encodeURI and encodeURIComponent here.

Note: List of characters that are supported in category/tag name after the change:

A–Z a–z 0–9 - _ . ! ~ * ' ( )

; / ? : @ & = + $ , #

What alternative solutions did you explore? (Optional)

I see there're several places where we use encodeURI, we should investigate if it is the correct usage there as well.

@jliexpensify
Copy link
Contributor

jliexpensify commented Mar 8, 2024

Posted here

I have reproduced the issue.

@melvin-bot melvin-bot bot added the Overdue label Mar 11, 2024
Copy link

melvin-bot bot commented Mar 11, 2024

@jliexpensify Whoops! This issue is 2 days overdue. Let's get this updated quick!

@tienifr
Copy link
Contributor

tienifr commented Mar 13, 2024

@jliexpensify Can you update the status?

@jliexpensify
Copy link
Contributor

@tienifr - I haven't gotten any responses from my Slack post: basically, I'm not sure if we use/are planning to use Parent/Child styles in New Expensify.

@melvin-bot melvin-bot bot removed the Overdue label Mar 13, 2024
@tienifr
Copy link
Contributor

tienifr commented Mar 13, 2024

@jliexpensify The problem is not only with / but with other special characters as well. So the basic question is whether we want category/tag name to include special charaters.

@mountiny mountiny added the External Added to denote the issue can be worked on by a contributor label Mar 13, 2024
Copy link

melvin-bot bot commented Mar 13, 2024

Job added to Upwork: https://www.upwork.com/jobs/~01425421b068a188c5

@melvin-bot melvin-bot bot changed the title Categories - Not here page shows up when opening Parent/ and Parent/: Child category [$500] Categories - Not here page shows up when opening Parent/ and Parent/: Child category Mar 13, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Mar 13, 2024
Copy link

melvin-bot bot commented Mar 13, 2024

Triggered auto assignment to Contributor-plus team member for initial proposal review - @hungvu193 (External)

@mountiny mountiny moved this to Release 1: Spring 2024 (May) in [#whatsnext] #wave-collect Mar 13, 2024
@mountiny mountiny changed the title [$500] Categories - Not here page shows up when opening Parent/ and Parent/: Child category [$500] [Wave Collect] [Categories] Categories - Not here page shows up when opening Parent/ and Parent/: Child category Mar 13, 2024
@mountiny
Copy link
Contributor

@tienifr and others, we would like to make sure this works with various special characters in the name of the category

@hungvu193
Copy link
Contributor

Reviewing shortly

@luacmartins luacmartins self-assigned this Mar 13, 2024
@hungvu193
Copy link
Contributor

Thanks for your proposal.
@tienifr 's proposal looks good to me. I checked other places that we used encodeURI inside url, most of them are static value.
There are 2 places that we're using encodeURI to encode the source but all of these are query param so it won't be a problem.

getRoute: (reportID: string, source: string) => `r/${reportID}/attachment?source=${encodeURI(source)}` as const,

getRoute: (source: string) => `settings/troubleshoot/console/share-log?source=${encodeURI(source)}` as const,

🎀 👀 🎀 C+ reviewed

Copy link

melvin-bot bot commented Mar 13, 2024

Current assignee @luacmartins is eligible for the choreEngineerContributorManagement assigner, not assigning anyone new.

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Mar 13, 2024
@jliexpensify jliexpensify added Bug Something is broken. Auto assigns a BugZero manager. and removed Bug Something is broken. Auto assigns a BugZero manager. labels Mar 19, 2024
Copy link

melvin-bot bot commented Mar 19, 2024

Current assignee @jliexpensify is eligible for the Bug assigner, not assigning anyone new.

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Mar 19, 2024
@jliexpensify jliexpensify removed their assignment Mar 19, 2024
@jliexpensify jliexpensify added Bug Something is broken. Auto assigns a BugZero manager. and removed Bug Something is broken. Auto assigns a BugZero manager. labels Mar 19, 2024
Copy link

melvin-bot bot commented Mar 19, 2024

Triggered auto assignment to @jliexpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@jliexpensify jliexpensify removed their assignment Mar 19, 2024
@jliexpensify jliexpensify added Bug Something is broken. Auto assigns a BugZero manager. and removed Bug Something is broken. Auto assigns a BugZero manager. labels Mar 19, 2024
Copy link

melvin-bot bot commented Mar 19, 2024

Triggered auto assignment to @mallenexpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@jliexpensify jliexpensify self-assigned this Mar 19, 2024
@jliexpensify
Copy link
Contributor

Hi @mallenexpensify - I am OOO from the 21st to 31st March. Here is what needs to be done:

PAYMENT SUMMARY (25TH)

  • C: @tienifr $500 (please accept offer)
  • C+: @hungvu193 $500 (please accept offer + complete checklist)

UPWORKS JOB

@hungvu193
Copy link
Contributor

  • The PR that introduced the bug has been identified. Link to the PR: feat: category settings page #37209
  • The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment: https://github.com/Expensify/App/pull/37209/files#r1529785049
  • A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion: N/A
  • Determine if we should create a regression test for this bug.

Regression test:
Precondition:
User is an admin of Collect workspace.

  1. Go to staging.new.expensify.com
  2. Go to Workspace settings > Collect workspace.
  3. Go to Categories.
  4. Click Add category.
  5. Add category in Parent/ and Parent/: Child format. And other special characters
  6. Click on the created category.
  7. Verify that Category RHP opens without issue.

Do we 👍 or 👎

@melvin-bot melvin-bot bot added the Overdue label Mar 25, 2024
@luacmartins
Copy link
Contributor

No need for regression tests. We'll add them as part of the design doc once the feature is fully implemented.

@melvin-bot melvin-bot bot removed the Overdue label Mar 27, 2024
@mallenexpensify
Copy link
Contributor

@tienifr @hungvu193 can you please accept the job and reply here once you have?
https://www.upwork.com/jobs/~01425421b068a188c5

@hungvu193
Copy link
Contributor

@tienifr @hungvu193 can you please accept the job and reply here once you have?

https://www.upwork.com/jobs/~01425421b068a188c5

Accepted! Thank you

@tienifr
Copy link
Contributor

tienifr commented Mar 30, 2024

@mallenexpensify I’ve accepted the offer, thanks!

@mallenexpensify
Copy link
Contributor

Contributor: @tienifr paid $500 via Upwork
Contributor+: @hungvu193 paid $500 via Upwork.

TestRail GH created - https://github.com/Expensify/Expensify/issues/383897

Thanks!

@github-project-automation github-project-automation bot moved this from Release 1: Spring 2024 (May) to Done in [#whatsnext] #wave-collect Mar 31, 2024
@jliexpensify
Copy link
Contributor

Thanks Matt, appreciate the assist!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor
Projects
No open projects
Archived in project
Development

No branches or pull requests

7 participants