Skip to content

fix: update IterSubjects for wildcards and Alias iterators for confomance#2864

Merged
barakmich merged 5 commits intomainfrom
barakmich/ls_wildcard_alias
Feb 3, 2026
Merged

fix: update IterSubjects for wildcards and Alias iterators for confomance#2864
barakmich merged 5 commits intomainfrom
barakmich/ls_wildcard_alias

Conversation

@barakmich
Copy link
Contributor

Description

Testing

References

@barakmich barakmich requested a review from a team as a code owner January 29, 2026 22:03
@github-actions github-actions bot added the area/tooling Affects the dev or user toolchain (e.g. tests, ci, build tools) label Jan 29, 2026
@barakmich barakmich marked this pull request as draft January 29, 2026 22:04
@codecov
Copy link

codecov bot commented Jan 29, 2026

Codecov Report

❌ Patch coverage is 66.66667% with 28 lines in your changes missing coverage. Please review.
✅ Project coverage is 74.33%. Comparing base (10cc7f7) to head (deb1327).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
pkg/query/alias.go 65.00% 27 Missing and 1 partial ⚠️

❌ Your project status has failed because the head coverage (74.33%) is below the target coverage (75.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2864      +/-   ##
==========================================
- Coverage   74.41%   74.33%   -0.07%     
==========================================
  Files         484      484              
  Lines       57792    57786       -6     
==========================================
- Hits        43000    42950      -50     
- Misses      11771    11812      +41     
- Partials     3021     3024       +3     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@barakmich barakmich force-pushed the barakmich/ls_wildcard_alias branch from b30a132 to 1525e5b Compare January 29, 2026 23:36
@github-actions github-actions bot added the area/datastore Affects the storage system label Jan 29, 2026
@barakmich barakmich force-pushed the barakmich/ls_wildcard_alias branch from 1525e5b to 75bf1a6 Compare January 30, 2026 19:31
@barakmich barakmich marked this pull request as ready for review January 30, 2026 19:31
Copy link
Contributor

@tstirrat15 tstirrat15 left a comment

Choose a reason for hiding this comment

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

Boy these are weird. I appreciate the way you documented them and tested them.

return
}
iter, err := ctx.Reader.QueryRelationships(ctx, filter,
options.WithLimit(options.LimitOne),
Copy link
Contributor

Choose a reason for hiding this comment

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

Wow, so the check logic is conditionally running to the datastore like this? Or is this more an artifact of the query planner having a different structure?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

More the different structure. Whereas in other LS implementations we just fetch where necessary, and in QP we've tried to keep it at the leaves. Unfortunately, this is something where the semantics break the expectation 😞

Copy link
Contributor

Choose a reason for hiding this comment

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

sadface

// subjects as the non-wildcard branch (when both wildcard and concrete relationships exist),
// but the Union will deduplicate them.
//
// Note: We query for all subjects of the appropriate type, not just those with a relationship
Copy link
Contributor

Choose a reason for hiding this comment

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

Wow... this feels kinda wild.

tstirrat15
tstirrat15 previously approved these changes Jan 30, 2026
Copy link
Contributor

@tstirrat15 tstirrat15 left a comment

Choose a reason for hiding this comment

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

LGTM

@barakmich barakmich merged commit ea09c1e into main Feb 3, 2026
43 of 45 checks passed
@barakmich barakmich deleted the barakmich/ls_wildcard_alias branch February 3, 2026 21:09
@github-actions github-actions bot locked and limited conversation to collaborators Feb 3, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area/datastore Affects the storage system area/tooling Affects the dev or user toolchain (e.g. tests, ci, build tools)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants