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

fix: navigating with UPDATE_EXISTED, extracting base route [WPB-5225] #2374

Merged
merged 1 commit into from
Oct 26, 2023

Conversation

saleniuk
Copy link
Contributor


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

The current code which has been used for months and has been moved around from place to place is faulty in cases when the path contains both path segments and parameters (path elements divided by slashes and arguments after the question mark) like path/segment?argument=value. Compose destinations generates non-nullable required navigation argument parameters as segments, and optional parameters as arguments.
Function to retrieve the base part of route first checks for the question mark and if it's found, it returns substring up to the question mark, which means when there's a question mark, it ignores slashes and returns path/segment instead of path.

Solutions

Change this function to find first occurrence of any of these characters (/, ?) and substring up to this first found element.

Testing

Test Coverage (Optional)

  • I have added automated test to this contribution

PR Post Submission Checklist for internal contributors (Optional)

  • Wire's Github Workflow has automatically linked the PR to a JIRA issue

PR Post Merge Checklist for internal contributors

  • If any soft of configuration variable was introduced by this PR, it has been added to the relevant documents and the CI jobs have been updated.

References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

@saleniuk saleniuk marked this pull request as ready for review October 25, 2023 15:04
@github-actions
Copy link
Contributor

Test Results

598 tests   597 ✔️  8m 40s ⏱️
  85 suites      1 💤
  85 files        0

Results for commit 5830e782.

@github-actions
Copy link
Contributor

APKs built during tests are available here. Scroll down to Artifacts!

@AndroidBob
Copy link
Collaborator

Build 1534 succeeded.

The build produced the following APK's:

@saleniuk saleniuk requested review from a team, gongracr, yamilmedina, mchenani and ohassine and removed request for a team October 25, 2023 16:12
@saleniuk saleniuk merged commit 3861d9b into release/candidate Oct 26, 2023
14 checks passed
@saleniuk saleniuk deleted the fix/navigation_comparing_routes branch October 26, 2023 08:44
@saleniuk saleniuk changed the title fix: navigating with UPDATE_EXISTED, extracting base route fix: navigating with UPDATE_EXISTED, extracting base route [WPB-5225] Oct 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
4 participants