Skip to content

Bugfix/globalagentscreation - #720

Merged
Paul Lizer (paullizer) merged 2 commits into
Developmentfrom
bugfix/globalagentscreation
Feb 23, 2026
Merged

Paul Lizer (paullizer) merged 2 commits into
Developmentfrom
bugfix/globalagentscreation

Conversation

@Bionic711

Copy link
Copy Markdown
Collaborator

Fixes the issue when creating global agents resulting from a validator that does not follow $refs.

@Bionic711 Bionic711 assigned Bionic711 and unassigned Bionic711 Feb 18, 2026
@Bionic711 Bionic711 added the bug Something isn't working label Feb 18, 2026
@Bionic711
Bionic711 requested a review from Copilot February 18, 2026 23:26

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes an agent validation issue where creating global agents failed with a PointerToNowhere: '/definitions/OtherSettings' error. The root cause was that the validator was incorrectly pointed at a sub-schema (schema['definitions']['Agent']) instead of the root schema, which stripped the shared definitions and broke JSON Schema $ref resolution. The fix updates validate_agent() to use the root schema with a proper RefResolver.

Changes:

  • Updated agent validation logic to use root schema and RefResolver for proper $ref resolution
  • Incremented application version from 0.237.011 to 0.237.049
  • Added comprehensive fix documentation

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
application/single_app/json_schema_validation.py Modified validate_agent() to use root schema with RefResolver instead of sub-schema
application/single_app/config.py Updated VERSION from "0.237.011" to "0.237.049"
docs/explanation/fixes/AGENT_SCHEMA_REF_RESOLUTION_FIX.md Added complete documentation of the fix including root cause, solution, and testing approach
Comments suppressed due to low confidence (2)

application/single_app/json_schema_validation.py:22

  • The conditional logic here may not work as intended. The check schema.get("$ref") and schema.get("definitions") will be true for the agent.schema.json (which has both), but the fix should apply unconditionally since the schema always has this structure. The else branch creates a validator without a resolver, which is the root cause of the bug being fixed. Consider simplifying this to always use the resolver when definitions exist, or remove the conditional entirely since agent.schema.json always has this structure.
    if schema.get("$ref") and schema.get("definitions"):
        validator = Draft7Validator(schema, resolver=RefResolver.from_schema(schema))
    else:
        validator = Draft7Validator(schema)

application/single_app/config.py:91

  • The version number jumps from 0.237.011 to 0.237.049, skipping many versions. According to the coding guidelines, only the third set of digits should be incremented by one. The version should be 0.237.012 instead of 0.237.049.
VERSION = "0.237.049"

Comment thread docs/explanation/fixes/AGENT_SCHEMA_REF_RESOLUTION_FIX.md

@paullizer Paul Lizer (paullizer) left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

straight forward

@paullizer
Paul Lizer (paullizer) merged commit 47d07da into Development Feb 23, 2026
9 of 10 checks passed
@paullizer
Paul Lizer (paullizer) deleted the bugfix/globalagentscreation branch February 23, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants