Skip to content

feat(effector): params schema subset - #596

Open
ccf-lisa[bot] wants to merge 1 commit into
effectors/04-targetsfrom
effectors/05-params-schema
Open

ccf-lisa[bot] wants to merge 1 commit into
effectors/04-targetsfrom
effectors/05-params-schema

Conversation

@ccf-lisa

@ccf-lisa ccf-lisa Bot commented Dec 1, 2026

Copy link
Copy Markdown
Contributor

What

New public package pkg/effector/params, part 1: the JSON Schema subset a plugin declares for an action's parameters (action parameters).

  • Parse / ValidateSchema: a root object; object, string (enum, maxLength, format: template with x-ccf-variables), boolean, integer (range, int64 only) and arrays of string enums; at most 3 levels of nesting; unknown keywords rejected with the property path (SchemaError).
  • Form hints: x-ccf-order (objects) and x-ccf-depends-on (a sibling boolean).
  • Each default is checked against its own field, through the private value validator; FieldError is the error it reports.
  • Lookup / HasPath for dotted parameter paths.

Ported from the PoC. Standard library only; nothing calls it yet.

Why

The API and the agent both check parameters with this package, so the API never accepts parameters the agent refuses. The package is split in two to stay under the size limit: this PR is the schema; the next one adds the public Validate, operator locks, defaults and the merge. Plan: stack 1, PR 5.

Test evidence

go test -cover ./pkg/effector/params: 86.3% (the public validation paths are covered by the next PR's tests).

Gate on this branch: go build ./... pass; go vet -tags integration ./... pass; make lint 0 new issues (6 pre-existing on main, untouched files); make test pass; make swag no diff; go mod tidy no diff. No integration tests in this package.

Size

Counted: 771 lines.

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Dec 1, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: ca1ea8c0-1272-4bab-be6d-55eb37f2320d

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
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

pkg/effector/params: parse and check the JSON Schema subset a plugin
declares for an action's parameters (object, string, boolean, integer,
string-enum arrays; nesting, length and range limits, template fields
and their variables, x-ccf-order and x-ccf-depends-on form hints).
Defaults are checked against their field
(docs/effectors/action-parameters.md).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@gusfcarvalho gusfcarvalho 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.

ccf-review: APPROVE

no findings.

Stack (gh stack 604): #592 → #593 → #594 → #595 → #596 → #597 → #598 → #599 → #600 → #601 → #602 → #603 → #605 → #606 → #607 → #608 → #609 → #610 → #611 → #612 → #613 → #614 → #615 → #616 → #617 → #618 → #619 → #620 → #621 → #622 → #623 → #624 → #625 → #626 → #627 → #628 → #629 → #630

This branch has not been deployed

No deployments
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