Skip to content

HotFix 2#1931

Merged
JoshuaSBrown merged 34 commits intostagingfrom
devel
Apr 1, 2026
Merged

HotFix 2#1931
JoshuaSBrown merged 34 commits intostagingfrom
devel

Conversation

@JoshuaSBrown
Copy link
Copy Markdown
Collaborator

@JoshuaSBrown JoshuaSBrown commented Apr 1, 2026

Summary by Sourcery

Update version metadata and fix schema ID version handling across web API and Foxx schema router.

Bug Fixes:

  • Ensure schema creation API appends a default ":0" version suffix when none is provided, matching Python client behavior.
  • Return schema IDs from the Foxx schema search API including the version suffix derived from the stored version field.

Enhancements:

  • Bump Foxx, Foxx API, and web component patch versions.
  • Refresh release timestamp metadata for the new hotfix build.

Build:

  • Update CMake-based release date and component version definitions for the new hotfix release.

JoshuaSBrown and others added 30 commits February 19, 2026 14:59
#1861)

* fix: prevent defaults being set to undefined, and interpret numbers and enums as strings.

* chore: Auto-format JavaScript files with Prettier
…nance, metricThread and task_worker (#1885)

Co-authored-by: Joshua S Brown <joshbro42867@yahoo.com>
Co-authored-by: Joshua S Brown <brownjs@ornl.gov>
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
…e and default to different database for tests (#1917)
… cmake (#1918)

Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
@sourcery-ai
Copy link
Copy Markdown
Contributor

sourcery-ai Bot commented Apr 1, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Updates release metadata and schema version handling to append an explicit ':' suffix on schema IDs, aligning the web service and Foxx API behavior with the Python client for schema create and search operations, and bumps related patch versions.

Sequence diagram for schema create with implicit version suffix handling

sequenceDiagram
    actor Client
    participant WebServer as WebServer_datafed_ws
    participant CoreAPI as Foxx_schema_router

    Client->>WebServer: POST /api/sch/create { id: schema_id, body: ... }
    alt id has no version suffix
        WebServer->>WebServer: Append ":0" to a_req.body.id
    else id already includes version suffix
        WebServer->>WebServer: Keep a_req.body.id unchanged
    end
    WebServer->>CoreAPI: sendMessage SchemaCreateRequest(id, body, ...)
    CoreAPI-->>WebServer: SchemaCreateReply
    WebServer-->>Client: JSON response
Loading

Sequence diagram for schema search returning version-qualified IDs

sequenceDiagram
    actor Client
    participant WebServer as WebServer_datafed_ws
    participant CoreAPI as Foxx_schema_router

    Client->>WebServer: POST /api/sch/search { query, offset, count }
    WebServer->>CoreAPI: sendMessage SchemaSearchRequest(query, offset, count, ...)
    CoreAPI->>CoreAPI: AQL RETURN {_id, id: CONCAT(i.id,':',TO_STRING(i.ver)), ver, ...}
    CoreAPI-->>WebServer: Search results with id including :ver suffix
    WebServer-->>Client: JSON results with version-qualified ids
Loading

File-Level Changes

Change Details Files
Update release metadata to reflect new hotfix build and component patch versions.
  • Change release date/time constants to April 1, 2026 14:00
  • Increment FOXX service patch version from 0 to 1
  • Increment FOXX API patch version from 0 to 1
  • Increment web component patch version from 0 to 1
cmake/Version.cmake
Normalize schema IDs on creation in the web service to ensure an explicit ':0' version suffix when none is provided.
  • Before sending SchemaCreateRequest, detect IDs without ':' and append ':0' to the ID field in the request body
  • Document this behavior with an inline comment referencing parity with the Python CommandLib
web/datafed-ws.js
Change schema search results from the Foxx API to return fully-qualified schema IDs that include the version suffix in the id field.
  • Modify AQL return projection so id is built as CONCAT(i.id,':',TO_STRING(i.ver)) instead of returning the base id
  • Keep the existing ver field intact while making id match the versioned identifier convention
core/database/foxx/api/schema_router.js

Possibly linked issues

  • #[Bug] - hotfix schema search in foxx: PR changes Foxx schema search to return id:version and enforces :0 suffix on schema creation, fixing issue.
  • #[Bug] - web, hotfix, schema version missing from id: Yes. PR appends version to schema IDs on create and in router, directly fixing missing schema version bug.

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • The id normalization to append :0 is currently applied only in web/datafed-ws.js; consider centralizing this logic on the backend (or in a shared helper) so all clients and code paths enforce the same schema ID format consistently.
  • In schema_router.js, CONCAT(i.id,':',TO_STRING(i.ver)) assumes i.id never already includes a version suffix; if that assumption might not always hold, add a guard or a short comment documenting the invariant to avoid accidentally double-appending versions in the future.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The `id` normalization to append `:0` is currently applied only in `web/datafed-ws.js`; consider centralizing this logic on the backend (or in a shared helper) so all clients and code paths enforce the same schema ID format consistently.
- In `schema_router.js`, `CONCAT(i.id,':',TO_STRING(i.ver))` assumes `i.id` never already includes a version suffix; if that assumption might not always hold, add a guard or a short comment documenting the invariant to avoid accidentally double-appending versions in the future.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@JoshuaSBrown JoshuaSBrown merged commit 2a3ed9f into staging Apr 1, 2026
3 checks passed
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