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 SurroundingDocsView with URI encoded chars in document id #8869

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

smortex
Copy link

@smortex smortex commented Nov 14, 2024

When viewing surrounding documents of a document which id contains chars
such as @ or +, these chars are encoded, preventing OpenSearch from
finding the requested document.

Decode the id to transform back the URI encoded chars to the actual
chars in the document id to find it and unbreak the feature.

Fixes #5711

Signed-off-by: Romain Tartière [email protected]

Changelog

  • skip

When viewing surrounding documents of a document which id contains chars
such as `@` or `+`, these chars are encoded, preventing OpenSearch from
finding the requested document.

Decode the id to transform back the URI encoded chars to the actual
chars in the document id to find it and unbreak the feature.

Fixes opensearch-project#5711

Signed-off-by: Romain Tartière <[email protected]>
Copy link
Contributor

❌ Invalid Changelog Heading

The '## Changelog' heading in your PR description is either missing or malformed. Please make sure that your PR description includes a '## Changelog' heading with proper spelling, capitalization, spacing, and Markdown syntax.

Copy link
Contributor

❌ Changelog Entry Missing Hyphen

Changelog entries must begin with a hyphen (-).

Copy link
Contributor

❌ Invalid Prefix For Manual Changeset Creation

Invalid description prefix. Found "fix". Only "skip" entry option is permitted for manual commit of changeset files.

If you were trying to skip the changelog entry, please use the "skip" entry option in the ##Changelog section of your PR description.

@github-actions github-actions bot added Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry and removed failed changeset labels Nov 14, 2024
@smortex smortex changed the title Fix SurroundingDocsView with URI encoded chars in id Fix SurroundingDocsView with URI encoded chars in document id Nov 15, 2024
Copy link
Member

@kavilla kavilla left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome thank you!

Copy link

codecov bot commented Nov 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 60.93%. Comparing base (413697d) to head (5c6f163).
Report is 6 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #8869   +/-   ##
=======================================
  Coverage   60.93%   60.93%           
=======================================
  Files        3800     3800           
  Lines       90878    90878           
  Branches    14323    14323           
=======================================
  Hits        55380    55380           
  Misses      31968    31968           
  Partials     3530     3530           
Flag Coverage Δ
Linux_1 29.01% <ø> (ø)
Linux_2 56.39% <ø> (ø)
Linux_3 37.92% <ø> (ø)
Linux_4 29.00% <ø> (ø)
Windows_1 29.02% <ø> (ø)
Windows_2 56.34% <ø> (ø)
Windows_3 37.92% <ø> (ø)
Windows_4 29.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x discover for discover reinvent discover-next first-time-contributor Skip-Changelog PRs that are too trivial to warrant a changelog or release notes entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Can't view surrounding documents when there's a "+" in the id
2 participants