Skip to content

Add isOdd factory SDK util#284

Closed
kjgbot wants to merge 1 commit into
mainfrom
ar-235-is-odd-v11b
Closed

Add isOdd factory SDK util#284
kjgbot wants to merge 1 commit into
mainfrom
ar-235-is-odd-v11b

Conversation

@kjgbot

@kjgbot kjgbot commented Jun 13, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add a pure isOdd(n) utility to factory-sdk
  • export it from the SDK index
  • add Vitest coverage for odd, even, and zero inputs

Validation

  • npx vitest run packages/factory-sdk/src/is-odd.test.ts

@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@coderabbitai

coderabbitai Bot commented Jun 13, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 4c0d669e-0c59-4893-bab6-6b69f9866ab1

📥 Commits

Reviewing files that changed from the base of the PR and between 7c4ab03 and e9ab9bb.

📒 Files selected for processing (3)
  • packages/factory-sdk/src/index.ts
  • packages/factory-sdk/src/is-odd.test.ts
  • packages/factory-sdk/src/is-odd.ts

📝 Walkthrough

Walkthrough

This PR adds a new isOdd utility function to the factory-sdk package. The implementation uses a modulo operator to check if a number is odd, includes three test cases validating behavior for odd, even, and zero values, and is re-exported from the package's public API.

Changes

isOdd utility function

Layer / File(s) Summary
isOdd implementation, tests, and export
packages/factory-sdk/src/is-odd.ts, packages/factory-sdk/src/is-odd.test.ts, packages/factory-sdk/src/index.ts
isOdd(n: number): boolean returns n % 2 !== 0 and is tested for odd (1), even (2), and zero (0) inputs. The function is re-exported in the module's public API barrel export.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

A rabbit hops with coding glee, 🐰
Adding isOdd for all to see,
Modulo checks the number's fate,
Tests confirm it's accurate!

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ar-235-is-odd-v11b

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed due to a network error.


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.

@kjgbot

kjgbot commented Jun 13, 2026

Copy link
Copy Markdown
Contributor Author

Closing per factory close-never-merge policy: synthetic [factory-e2e] probe PR from fv2's (B) live-gate dispatch. Never merged. (Auto-close fix #280 already merged; live auto-close pending (C) completion-detection.)

@kjgbot kjgbot closed this Jun 13, 2026
@agent-relay-code

Copy link
Copy Markdown
Contributor

Reviewed PR #284 against the checked-out diff and traced the new factory-sdk export/test path. I found no demonstrated breakage and made no code changes.

Addressed comments

  • gemini-code-assist[bot]: quota-limit warning only; no actionable code finding, so no change.
  • coderabbitai[bot]: walkthrough plus ESLint tool network failure; validated current checkout locally instead. No code change needed; isOdd remains at packages/factory-sdk/src/is-odd.ts:1, tests at packages/factory-sdk/src/is-odd.test.ts:5, export at packages/factory-sdk/src/index.ts:25.
  • kjgbot: PR closure notice for synthetic factory policy; not a code finding, so no change.

Validation

  • npm run verify:mcp-resources-drift: pass
  • npm run lint: pass with existing warnings only
  • npm run typecheck:web: pass
  • npm run typecheck:node: pass
  • npm test: pass, 122 tests
  • npx vitest run: pass, 54 files / 730 tests
  • npm run build: pass

Advisory Notes

None. The PR is closed per bot policy, so I am not marking it ready.

@agent-relay-code

Copy link
Copy Markdown
Contributor

Reviewed PR #284 against .workforce/pr.diff, changed files, current checkout, and PR comments. I found no demonstrated breakage and made no code changes.

Addressed comments

  • gemini-code-assist[bot]: quota-limit warning only; no actionable code finding, so no change.
  • coderabbitai[bot]: walkthrough plus ESLint tool network failure; validated current checkout locally. No code change needed; implementation is at packages/factory-sdk/src/is-odd.ts:1, tests at packages/factory-sdk/src/is-odd.test.ts:5, export at packages/factory-sdk/src/index.ts:25.
  • kjgbot: PR closure notice for synthetic factory close-never-merge policy; not a code finding, so no change.
  • agent-relay-code[bot]: prior review reported no demonstrated breakage; revalidated current checkout and found the same, so no change.

Validation

  • npm ci: pass
  • npm run verify:mcp-resources-drift: pass
  • npm run lint: pass with existing warnings only
  • npm run typecheck:web: pass
  • npm run typecheck:node: pass
  • npm test: pass, 122 tests
  • npx vitest run: pass, 54 files / 730 tests
  • npm run build: pass
  • npm run build:web: pass
  • npx playwright test --config playwright.fidelity.config.ts: pass, 7 tests
  • npx playwright test --config playwright.redraw.config.ts: pass, 1 test
  • Final npm run verify:mcp-resources-drift: pass

Advisory Notes

None.

PR metadata currently reports the PR is closed and unmerged, so I am not marking it ready.

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