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

Gregsdennis/improve scopes #1588

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

gregsdennis
Copy link
Member

What kind of change does this PR introduce?

clarification

Issue & Discussion References

Summary

Improve readability, definitions, and explanations of lexical and dynamic scopes.

Does this PR introduce a breaking change?

No.

There is a MUST requirement that was previously listed as undefined behavior before, but this MUST was stated in the scopes section anyway. It's just now MUST in both places.

@gregsdennis gregsdennis requested a review from a team February 25, 2025 05:31
@gregsdennis gregsdennis self-assigned this Feb 25, 2025
@gregsdennis gregsdennis added this to the stable-release milestone Feb 25, 2025
@gregsdennis
Copy link
Member Author

I still have some work to do here for $dynamic*, but I'm going to wait until #1589 is done so I can rebase on that.

@gregsdennis gregsdennis reopened this Apr 12, 2025
@github-project-automation github-project-automation bot moved this from In Progress to Done in Stable Release Development Apr 12, 2025
@gregsdennis gregsdennis reopened this Apr 12, 2025
@gregsdennis
Copy link
Member Author

Just did a close/open to rekick the build. It had been a while and couldn't do it manually.

@gregsdennis gregsdennis moved this from Done to In Progress in Stable Release Development Apr 12, 2025
@gregsdennis gregsdennis marked this pull request as ready for review April 12, 2025 01:28
@gregsdennis
Copy link
Member Author

Reviewed the changes in #1589, and they seem to align with the rest of what I've updated here, so I'm going to leave $dynamic* as it is.

@gregsdennis gregsdennis force-pushed the gregsdennis/improve-scopes branch from 8f29265 to 767debd Compare April 12, 2025 02:05
Copy link
Member

@jdesrosiers jdesrosiers left a comment

Choose a reason for hiding this comment

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

This is an improvement, but I still really dislike the way dynamic scope is defined. I think it should be the stack of schema resources and not include subschemas. The extra complexity makes learning how dynamic references work more complicated.

Also, I desperately hope we wouldn't ever add another keyword that uses dynamic scope. My preference would be to remove this whole concept from the spec and address it only in the context of dynamic references and recommend that extension keywords not use dynamic scope.

All of that can be debated elsewhere and done as a follow up if there's consensus.

Comment on lines -467 to +476
root schema.
root object.
Copy link
Member

Choose a reason for hiding this comment

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

I think "root schema" is better here. Yes, it's an object, but more specifically, it's a schema. Maybe "root schema object" or "root object schema" if you want to be clear that boolean schemas aren't relevant.

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

Successfully merging this pull request may close these issues.

🧹 Clarification: Scopes section could be improved
2 participants