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(core): include _originalId in groq2024 search, update refs adapter #8395

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

Conversation

pedrobonamin
Copy link
Contributor

Description

Fixes a bug that occurs when using groq2024 search and trying to create a reference to a document that is only a draft, no published version of this document exists.

The problem is that when using groq2024 the results include the document published id, even if it's a published or a draft, I think this is because it is using a perspective to query the data.

To fix this we include the _originalId which represents the real id of the document, which is the drafts or version (coming soon)

Refs.error.mov

What to review

Is this change correct?

Testing

groq 2024 tests have been updated.

Notes for release

fixes a regression in which references to non published documents fails when using groq2024 search strategy

@pedrobonamin pedrobonamin requested a review from a team as a code owner January 24, 2025 09:08
@pedrobonamin pedrobonamin requested review from RitaDias and removed request for a team January 24, 2025 09:08
Copy link

vercel bot commented Jan 24, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
page-building-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 24, 2025 9:11am
performance-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 24, 2025 9:11am
test-studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 24, 2025 9:11am
2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
studio-workshop ⬜️ Ignored (Inspect) Jan 24, 2025 9:11am
test-next-studio ⬜️ Ignored (Inspect) Jan 24, 2025 9:11am

@pedrobonamin pedrobonamin requested a review from juice49 January 24, 2025 09:08
Copy link
Contributor

No changes to documentation

Copy link
Contributor

Component Testing Report Updated Jan 24, 2025 9:15 AM (UTC)

❌ Failed Tests (1) -- expand for details
File Status Duration Passed Skipped Failed
comments/CommentInput.spec.tsx ✅ Passed (Inspect) 1m 6s 15 0 0
formBuilder/ArrayInput.spec.tsx ✅ Passed (Inspect) 12s 3 0 0
formBuilder/inputs/PortableText/Annotations.spec.tsx ❌ Failed (Inspect) 1m 20s 5 0 1
formBuilder/inputs/PortableText/copyPaste/CopyPaste.spec.tsx ✅ Passed (Inspect) 50s 11 7 0
formBuilder/inputs/PortableText/copyPaste/CopyPasteFields.spec.tsx ✅ Passed (Inspect) 0s 0 12 0
formBuilder/inputs/PortableText/Decorators.spec.tsx ✅ Passed (Inspect) 25s 6 0 0
formBuilder/inputs/PortableText/DisableFocusAndUnset.spec.tsx ✅ Passed (Inspect) 14s 3 0 0
formBuilder/inputs/PortableText/DragAndDrop.spec.tsx ✅ Passed (Inspect) 26s 6 0 0
formBuilder/inputs/PortableText/FocusTracking.spec.tsx ✅ Passed (Inspect) 1m 6s 15 0 0
formBuilder/inputs/PortableText/Input.spec.tsx ✅ Passed (Inspect) 1m 32s 21 0 0
formBuilder/inputs/PortableText/ObjectBlock.spec.tsx ✅ Passed (Inspect) 2m 1s 21 0 0
formBuilder/inputs/PortableText/PresenceCursors.spec.tsx ✅ Passed (Inspect) 13s 3 9 0
formBuilder/inputs/PortableText/Styles.spec.tsx ✅ Passed (Inspect) 26s 6 0 0
formBuilder/inputs/PortableText/Toolbar.spec.tsx ✅ Passed (Inspect) 1m 43s 21 0 0
formBuilder/tree-editing/TreeEditing.spec.tsx ✅ Passed (Inspect) 0s 0 3 0
formBuilder/tree-editing/TreeEditingNestedObjects.spec.tsx ✅ Passed (Inspect) 0s 0 3 0

Copy link
Contributor

⚡️ Editor Performance Report

Updated Fri, 24 Jan 2025 09:20:33 GMT

Benchmark reference
latency of sanity@latest
experiment
latency of this branch
Δ (%)
latency difference
article (title) 26.3 efps (38ms) 25.6 efps (39ms) +1ms (+2.6%)
article (body) 72.5 efps (14ms) 72.2 efps (14ms) +0ms (-/-%)
article (string inside object) 27.8 efps (36ms) 26.3 efps (38ms) +2ms (+5.6%)
article (string inside array) 24.4 efps (41ms) 22.7 efps (44ms) +3ms (+7.3%)
recipe (name) 52.6 efps (19ms) 55.6 efps (18ms) -1ms (-5.3%)
recipe (description) 58.8 efps (17ms) 62.5 efps (16ms) -1ms (-5.9%)
recipe (instructions) 99.9+ efps (5ms) 99.9+ efps (5ms) +0ms (-/-%)
synthetic (title) 18.3 efps (55ms) 19.6 efps (51ms) -4ms (-6.4%)
synthetic (string inside object) 17.9 efps (56ms) 18.7 efps (54ms) -3ms (-4.5%)

efps — editor "frames per second". The number of updates assumed to be possible within a second.

Derived from input latency. efps = 1000 / input_latency

Detailed information

🏠 Reference result

The performance result of sanity@latest

Benchmark latency p75 p90 p99 blocking time test duration
article (title) 38ms 44ms 69ms 324ms 250ms 10.6s
article (body) 14ms 17ms 21ms 78ms 84ms 5.0s
article (string inside object) 36ms 40ms 49ms 200ms 208ms 6.6s
article (string inside array) 41ms 44ms 49ms 96ms 279ms 6.9s
recipe (name) 19ms 21ms 23ms 41ms 0ms 6.8s
recipe (description) 17ms 18ms 20ms 37ms 0ms 4.3s
recipe (instructions) 5ms 7ms 9ms 42ms 0ms 3.1s
synthetic (title) 55ms 57ms 63ms 277ms 1006ms 12.7s
synthetic (string inside object) 56ms 61ms 71ms 263ms 1256ms 9.0s

🧪 Experiment result

The performance result of this branch

Benchmark latency p75 p90 p99 blocking time test duration
article (title) 39ms 43ms 61ms 494ms 758ms 11.0s
article (body) 14ms 16ms 23ms 96ms 118ms 5.1s
article (string inside object) 38ms 41ms 54ms 176ms 163ms 6.7s
article (string inside array) 44ms 46ms 53ms 188ms 198ms 7.0s
recipe (name) 18ms 20ms 23ms 38ms 0ms 7.3s
recipe (description) 16ms 17ms 18ms 20ms 0ms 4.2s
recipe (instructions) 5ms 6ms 7ms 17ms 0ms 3.0s
synthetic (title) 51ms 54ms 61ms 230ms 670ms 12.7s
synthetic (string inside object) 54ms 55ms 69ms 164ms 629ms 7.8s

📚 Glossary

column definitions

  • benchmark — the name of the test, e.g. "article", followed by the label of the field being measured, e.g. "(title)".
  • latency — the time between when a key was pressed and when it was rendered. derived from a set of samples. the median (p50) is shown to show the most common latency.
  • p75 — the 75th percentile of the input latency in the test run. 75% of the sampled inputs in this benchmark were processed faster than this value. this provides insight into the upper range of typical performance.
  • p90 — the 90th percentile of the input latency in the test run. 90% of the sampled inputs were faster than this. this metric helps identify slower interactions that occurred less frequently during the benchmark.
  • p99 — the 99th percentile of the input latency in the test run. only 1% of sampled inputs were slower than this. this represents the worst-case scenarios encountered during the benchmark, useful for identifying potential performance outliers.
  • blocking time — the total time during which the main thread was blocked, preventing user input and UI updates. this metric helps identify performance bottlenecks that may cause the interface to feel unresponsive.
  • test duration — how long the test run took to complete.

Copy link
Contributor

@RitaDias RitaDias left a comment

Choose a reason for hiding this comment

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

Nice! This looks good to me, though since @juice49 is the one that touched on this lately might be worth him giving a once-over :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants