Skip to content

v10.0.8 - #35

Merged
yilmaztayfun merged 2 commits into
release-v1.0from
master
Jun 8, 2026
Merged

v10.0.8#35
yilmaztayfun merged 2 commits into
release-v1.0from
master

Conversation

@yilmaztayfun

@yilmaztayfun yilmaztayfun commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Summary by Sourcery

Add CLI user-agent identification to API requests and extend mappings support in workflow detection and documentation.

New Features:

  • Support mappings as a first-class component type in workflow detection and project configuration.

Enhancements:

  • Include a versioned CLI User-Agent header on all API health, publish, and re-initialize requests for better server-side identification.
  • Document mappings paths and examples in the README and add contributor guidance for Claude Code in a new CLAUDE.md file.

Documentation:

  • Update README to describe mappings support and configuration, and add a CLAUDE.md guide for working with the repository using Claude Code.

yilmaztayfun and others added 2 commits June 8, 2026 23:22
Register the new "mappings" (Mappings/) system component so that
components under that folder map to the sys-mappings flow. The mapping
is added to both the config-driven switch and the path-based fallback
in detectComponentType; folder discovery, the reset menu, check, and
sync stay config-driven and need no changes.

Also send a "User-Agent: vnext-workflow-cli/<version>" header on all
outbound API calls (health, publish, re-initialize) so the vNext API
can identify requests originating from the CLI.

Adds CLAUDE.md with architecture guidance for future contributors.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…-component-referenced-custom-c-script-helpers

feat(cli): add sys-mappings component type and CLI User-Agent header
@yilmaztayfun yilmaztayfun self-assigned this Jun 8, 2026
@yilmaztayfun
yilmaztayfun requested review from a team June 8, 2026 20:24
@sourcery-ai

sourcery-ai Bot commented Jun 8, 2026

Copy link
Copy Markdown

Reviewer's Guide

Adds a CLI-identifying User-Agent header to all axios API calls, extends workflow component handling and documentation to support a new 'mappings' type, and introduces a CLAUDE.md guide describing the repository architecture and usage for AI tooling.

Sequence diagram for axios API calls with CLI User-Agent

sequenceDiagram
    participant CLI as CLI
    participant api as api_js
    participant Axios as axios
    participant vNextAPI as vNext_API

    CLI->>api: publishComponent(baseUrl, componentData)
    api->>Axios: post("/api/v1/definitions/publish", componentData, { headers: { User-Agent: USER_AGENT } })
    Axios->>vNextAPI: HTTP POST /api/v1/definitions/publish
    vNextAPI-->>Axios: 200 OK / error
    Axios-->>api: response / error
    api-->>CLI: publish result
Loading

File-Level Changes

Change Details Files
Tag all outgoing CLI API requests with a versioned User-Agent header.
  • Import package.json to read the CLI version at runtime.
  • Define a USER_AGENT constant in the API helper module.
  • Attach the User-Agent header to the /health test request.
  • Attach the User-Agent header to the component publish POST request.
  • Attach the User-Agent header to the system reinitialization GET request.
src/lib/api.js
Document and wire in support for a new 'mappings' component type in discovery/type detection and README config examples.
  • Update CLI description and configuration examples to mention mappings as a first-class component type.
  • Add paths.mappings to the vnext.config.json configuration documentation and sample tree.
  • Extend detectComponentType to map a configured 'mappings' path to sys-mappings.
  • Extend path-based fallback detection to treat /mappings/ paths as sys-mappings.
README.md
src/lib/workflow.js
Add CLAUDE.md to document project architecture and conventions for AI-assisted code tools.
  • Describe the CLI’s purpose, commands, and runtime model.
  • Explain the two configuration systems and their interaction.
  • Outline the high-level architecture of commands and libraries, including API and DB access patterns.
  • Document command semantics, git-based discovery behavior, and coding conventions.
CLAUDE.md

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

@coderabbitai

coderabbitai Bot commented Jun 8, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: c2a957cc-5006-4533-9b85-86fd27354657

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch master

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@yilmaztayfun
yilmaztayfun merged commit 0f696f6 into release-v1.0 Jun 8, 2026
3 of 5 checks passed
@sonarqubecloud

sonarqubecloud Bot commented Jun 8, 2026

Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!


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.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request introduces support for a new "mappings" component type (sys-mappings), updating the documentation, configuration, and detection logic. It also adds a custom User-Agent header to all outgoing API requests. A review comment highlights a cross-platform compatibility issue on Windows where path separator checks using forward slashes will fail, and suggests normalizing the path separators or using a regular expression to handle both slashes and backslashes.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread src/lib/workflow.js
if (pathLower.includes('/functions/')) return 'sys-functions';
if (pathLower.includes('/extensions/')) return 'sys-extensions';

if (pathLower.includes('/mappings/')) return 'sys-mappings';

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

high

On Windows systems, file paths use backslashes (\\) instead of forward slashes (/). Since pathLower is derived directly from jsonPath (which contains platform-specific separators), checks like pathLower.includes('/mappings/') or the dynamic folderPattern check (e.g., /${folderName.toLowerCase()}/) will fail on Windows.

To make this fully cross-platform, you should normalize the path separators to forward slashes at the beginning of the detectComponentType function.

For example, at the start of detectComponentType (line 33):

const pathLower = jsonPath.toLowerCase().replace(/\\/g, '/');

If you normalize the path separators at the top of the function, the existing forward-slash checks will work seamlessly on all platforms, and you can keep this line as is. Otherwise, you can use a regex to support both separators here.

Suggested change
if (pathLower.includes('/mappings/')) return 'sys-mappings';
if (/[/\\]mappings[/\\]/.test(pathLower)) return 'sys-mappings';

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.

1 participant