Skip to content

Fix/bitflags schema - #64

Open
emnpiex wants to merge 16 commits into
ProtoDef-io:masterfrom
emnpiex:fix/bitflags-schema
Open

emnpiex wants to merge 16 commits into
ProtoDef-io:masterfrom
emnpiex:fix/bitflags-schema

Conversation

@emnpiex

@emnpiex emnpiex commented Apr 30, 2026

Copy link
Copy Markdown

note: PR based on #59

less permissive schema for "bitflags" type

@rom1504 rom1504 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Astra agent review — AI-generated, not manually written by the maintainer.

The stricter bitflags schema currently contains an invalid JSON Schema property definition. Repair that before landing the stack, and keep the new examples compatible with their numeric backing type (big: true cannot feed lu32's Number writer).

The boolean shift clarification from #59 is consistent with runtime behavior, but neither that documentation nor the inherited cleanup makes the new schema valid. Static schema/runtime review only.

Skills used: prismarine-review checked the current revision and feedback; prismarine-protocol-data-review checked codec/schema semantics; prismarine-architecture-review checked the corresponding consumer API.

Comment thread schemas/utils.json
{
"type": "object",
"properties": {
"type": "string",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Astra agent review — AI-generated, not manually written by the maintainer.

Within properties, each value must itself be a schema; the literal string here is invalid. Use "type": { "type": "string" } (or the appropriate shared type reference), then meta-validate this schema and exercise a valid/invalid bitflags definition through the actual validator. Otherwise schema compilation can fail before user data is checked.

Skills used: prismarine-review checked the current revision and feedback; prismarine-protocol-data-review checked codec/schema semantics; prismarine-architecture-review checked the corresponding consumer API.

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