Skip to content

Conversation

@miparnisari
Copy link
Contributor

@miparnisari miparnisari commented Dec 30, 2025

No functional changes.

  • A few renames
  • Simplified the setup of some unit tests that don't need a full blown datastore to pass

@github-actions github-actions bot added the area/tooling Affects the dev or user toolchain (e.g. tests, ci, build tools) label Dec 30, 2025
@codecov
Copy link

codecov bot commented Dec 30, 2025

Codecov Report

❌ Patch coverage is 94.28571% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 77.69%. Comparing base (8a6d4a9) to head (8eb66d5).

Files with missing lines Patch % Lines
pkg/development/schema_position_mapper.go 85.72% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2794      +/-   ##
==========================================
- Coverage   77.71%   77.69%   -0.02%     
==========================================
  Files         472      472              
  Lines       49709    49708       -1     
==========================================
- Hits        38627    38616      -11     
- Misses       8231     8237       +6     
- Partials     2851     2855       +4     

☔ 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.

@miparnisari miparnisari marked this pull request as ready for review December 30, 2025 00:17
@miparnisari miparnisari requested a review from a team as a code owner December 30, 2025 00:17
@@ -62,21 +62,21 @@ type SchemaReference struct {
TargetNamePositionOffset int
}

// Resolver resolves references to schema nodes from source positions.
type Resolver struct {
Copy link
Contributor Author

@miparnisari miparnisari Dec 30, 2025

Choose a reason for hiding this comment

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

i was confused by the existence of this struct and pkg/schema/resolver.go so i renamed both

// Check the caveat, if any.
if allowedRelation.GetRequiredCaveat() != nil {
_, err := def.TypeSystem().resolver.LookupCaveat(ctx, allowedRelation.GetRequiredCaveat().CaveatName)
_, err := def.TypeSystem().GetCaveat(ctx, allowedRelation.GetRequiredCaveat().CaveatName)
Copy link
Contributor Author

@miparnisari miparnisari Dec 30, 2025

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

Like in the sense that it prevents the caller from needing to reach into the struct? I agree with the refactor but I don't really understand what the link is asserting.

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.

This makes sense to me. I think I'd want to get Barak or Joey's eyes on it.

// Check the caveat, if any.
if allowedRelation.GetRequiredCaveat() != nil {
_, err := def.TypeSystem().resolver.LookupCaveat(ctx, allowedRelation.GetRequiredCaveat().CaveatName)
_, err := def.TypeSystem().GetCaveat(ctx, allowedRelation.GetRequiredCaveat().CaveatName)
Copy link
Contributor

Choose a reason for hiding this comment

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

Like in the sense that it prevents the caller from needing to reach into the struct? I agree with the refactor but I don't really understand what the link is asserting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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.

3 participants