Skip to content

action: add baseline mode#1360

Merged
EffortlessSteven merged 1 commit into
mainfrom
action-baseline-mode
Apr 28, 2026
Merged

action: add baseline mode#1360
EffortlessSteven merged 1 commit into
mainfrom
action-baseline-mode

Conversation

@EffortlessSteven

Copy link
Copy Markdown
Member

Summary

  • add mode: baseline to the root GitHub Action
  • add a baseline-report output pointing to tokmd-baseline.json
  • require exactly one parsed path for baseline mode, matching the single-path CLI contract
  • include the baseline file in uploaded artifacts
  • preserve omitted/module/export/gate/cockpit/sensor behavior and the gate single-path guard
  • document baseline mode in the README and add Action self-test coverage
  • fix a small Halstead tokenizer UTF-8 panic discovered by running baseline against the repo

Validation

  • cargo run -p tokmd -- baseline . --output $env:TEMP\\tokmd-baseline-action-smoke.json --force --no-progress
  • cargo test -p tokmd-analysis --features halstead tokenize_handles_non_ascii_after_operator
  • git diff --check
  • cargo fmt-check
  • cargo xtask publish-surface --json
  • cargo xtask publish-surface --json --verify-publish
  • cargo xtask gate --check
  • cargo deny --all-features check (passed with existing duplicate/advisory warnings)

Deferred

  • browser-runner cache/progress/auth-fetch
  • v2 performance/cache work

@coderabbitai

coderabbitai Bot commented Apr 28, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@EffortlessSteven has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 28 minutes and 18 seconds before requesting another review.

To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 57e5c0eb-e0c3-4517-8d10-b7a3d6c617f9

📥 Commits

Reviewing files that changed from the base of the PR and between 0cc796a and 291b449.

📒 Files selected for processing (4)
  • .github/workflows/test-action.yml
  • README.md
  • action.yml
  • crates/tokmd-analysis/src/halstead/mod.rs
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch action-baseline-mode

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.

@github-actions

github-actions Bot commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

Glass Cockpit

Base: origin/main
Head: HEAD

Change Surface:

  • Files: 4
  • Insertions: 151
  • Deletions: 13

Composition:

  • Code: 25.0%
  • Test: 0.0%
  • Docs: 25.0%
  • Config: 50.0%

Contracts:

  • API: Yes
  • CLI: No
  • Schema: No

Health: 80/100 (B)
Risk: low (20/100)

Review Plan

  • .github/workflows/test-action.yml (priority: 2)
  • README.md (priority: 3)
  • action.yml (priority: 3)
  • crates/tokmd-analysis/src/halstead/mod.rs (priority: 3)

Receipts

Full receipt data available in JSON format.

@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 a new baseline mode to the tokmd action, updating the documentation, inputs, and outputs accordingly. The implementation in action.yml now supports running tokmd baseline with a single path requirement. Additionally, the Halstead tokenization logic in crates/tokmd-analysis/src/halstead/mod.rs was improved to handle non-ASCII characters correctly by using character vectors instead of byte-indexed string slicing, supported by a new test case. I have no feedback to provide.

@EffortlessSteven EffortlessSteven merged commit 1c0f16d into main Apr 28, 2026
25 checks passed
@EffortlessSteven EffortlessSteven deleted the action-baseline-mode branch April 28, 2026 11:28
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