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

[$250] Report fields - Unable to save content in text report field if there is no space at the end #48106

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

Comments

@IuliiaHerets
Copy link

IuliiaHerets commented Aug 27, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 9.0.25-3
Reproducible in staging?: Y
Reproducible in production?: N
Email or phone of affected tester (no customers): applausetester+kh05081@applause.expensifail.com
Issue reported by: Applause Internal Team

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to workspace settings > Report fields.
  3. Click Add field.
  4. Create a text type report field, without initial value.
  5. Click on the added text type report field.
  6. Click Initial value.
  7. Enter anything without space at the end of text and save it.
  8. Note that the content is not saved when there is no space at the end.
  9. Click Initial value.
  10. Enter anything, followed by a space, and save it.
  11. Note that the content is saved when there is space at the end.

Expected Result:

Content without space at the end should be saved.

Actual Result:

Content without space at the end is not saved when editing text type report field.
This issue only happens with the created text type report field, and not while the report field is being created.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug6584306_1724775424979.bandicam_2024-08-28_00-10-14-839.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~016970107b81b06f81
  • Upwork Job ID: 1828482902901740534
  • Last Price Increase: 2024-08-27
  • Automatic offers:
    • cretadn22 | Contributor | 103705877
    • ishpaul777 | Contributor | 103705905
Issue OwnerCurrent Issue Owner: @ishpaul777
@IuliiaHerets IuliiaHerets added DeployBlockerCash This issue or pull request should block deployment Bug Something is broken. Auto assigns a BugZero manager. labels Aug 27, 2024
Copy link

melvin-bot bot commented Aug 27, 2024

Triggered auto assignment to @chiragsalian (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

Copy link

melvin-bot bot commented Aug 27, 2024

Triggered auto assignment to @dylanexpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

@melvin-bot melvin-bot bot added the Daily KSv2 label Aug 27, 2024
@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Aug 27, 2024
Copy link
Contributor

👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

  1. Identify the pull request that introduced this issue and revert it.
  2. Find someone who can quickly fix the issue.
  3. Fix the issue yourself.

@IuliiaHerets
Copy link
Author

We think that this bug might be related to #wave-control

Copy link

melvin-bot bot commented Aug 27, 2024

📣 @YeGop0218! 📣
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:

  1. Make sure you've read and understood the contributing guidelines.
  2. Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
  3. Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
  4. Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
    Screen Shot 2022-11-16 at 4 42 54 PM
    Format:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>

@cretadn22
Copy link
Contributor

Proposal

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

Unable to save content in text report field if there is no space at the end

What is the root cause of that problem?

ReportField.updateReportFieldInitialValue(policyID, reportFieldID, initialValue === values.initialValue ? '' : values.initialValue);

ReportField.updateReportFieldInitialValue(policyID, reportFieldID, initialValue === value ? '' : value);

initialValue === value.initialValue always be true because initialValue is updated every time the text changes

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

Use WorkspaceReportFieldUtils.getReportFieldInitialValue(reportField) to check if the user has updated the old value instead of relying on the initialValue state, as WorkspaceReportFieldUtils.getReportFieldInitialValue(reportField) will always return the old value.

When the new value is similar to the old value, handle the updates as follows:

Text type: No action required.
List type: Update the initial value to an empty string.

What alternative solutions did you explore? (Optional)

@cretadn22
Copy link
Contributor

The Offending PR: #47828

@chiragsalian
Copy link
Contributor

Nice, your solution LGTM, how quickly can you push up a PR for this @cretadn22? Asking cause its hourly. So the sooner the better.

@chiragsalian chiragsalian added the External Added to denote the issue can be worked on by a contributor label Aug 27, 2024
@melvin-bot melvin-bot bot changed the title Report fields - Unable to save content in text report field if there is no space at the end [$250] Report fields - Unable to save content in text report field if there is no space at the end Aug 27, 2024
Copy link

melvin-bot bot commented Aug 27, 2024

Job added to Upwork: https://www.upwork.com/jobs/~016970107b81b06f81

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 27, 2024
Copy link

melvin-bot bot commented Aug 27, 2024

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

@chiragsalian chiragsalian assigned cretadn22 and unassigned ishpaul777 Aug 27, 2024
@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 27, 2024
@cretadn22
Copy link
Contributor

@chiragsalian The PR is ready soon

Copy link

melvin-bot bot commented Aug 27, 2024

📣 @cretadn22 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
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 📖

@ishpaul777
Copy link
Contributor

Does that not require a c+?

Copy link

melvin-bot bot commented Aug 27, 2024

📣 @ishpaul777 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
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 📖

@chiragsalian
Copy link
Contributor

chiragsalian commented Aug 27, 2024

oops i didnt mean to unassign @ishpaul777 earlier. I think that was some race condition when i added cretadn.
But yeah since this is a blocker for deploy I'm fine with skipping C+ for this.

@chiragsalian
Copy link
Contributor

but hey @ishpaul777, if you are around and available to help out I'll gladly accept the help 🙂 I'd just like this to be addressed soon so it doesn't block deploy.

@ishpaul777
Copy link
Contributor

yes i'll be around to help review PR :D

@chiragsalian
Copy link
Contributor

chiragsalian commented Aug 28, 2024

CP-d a fix. Tested on staging web and it LGTM. Removing blocker label and checking it off the checklist.

@chiragsalian chiragsalian removed the DeployBlockerCash This issue or pull request should block deployment label Aug 28, 2024
@ishpaul777
Copy link
Contributor

Deployed in this checklist #48221, Paydate 6 sept. Plaase help remove Reviewing label and Add Awaiting payment 🙏

@chiragsalian chiragsalian added Awaiting Payment Auto-added when associated PR is deployed to production and removed Reviewing Has a PR in review labels Sep 5, 2024
Copy link

melvin-bot bot commented Sep 10, 2024

@chiragsalian @dylanexpensify @ishpaul777 @cretadn22 this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

@dylanexpensify
Copy link
Contributor

Payment summary:

Contributor: @cretadn22 $250
Contributor+: @ishpaul777 $250

Please apply/request!

@dylanexpensify
Copy link
Contributor

paid!

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. Engineering External Added to denote the issue can be worked on by a contributor Weekly KSv2
Projects
None yet
Development

No branches or pull requests

5 participants