Skip to content

docs(tradable): explain component check#858

Merged
TobiTenno merged 4 commits intoWFCD:masterfrom
Clarity-89:fix/tradable-status
Feb 23, 2026
Merged

docs(tradable): explain component check#858
TobiTenno merged 4 commits intoWFCD:masterfrom
Clarity-89:fix/tradable-status

Conversation

@Clarity-89
Copy link
Copy Markdown
Contributor

@Clarity-89 Clarity-89 commented Feb 12, 2026

And a comment to clarify how the tradable status is computed.

Considerations

  • Does this contain a new dependency? [No]
  • Does this introduce opinionated data formatting or manual data entry? [No]
  • Does this pr include updated data files in a separate commit that can be reverted for a clean code-only pr? [No]
  • Have I run the linter? [Yes]
  • Is is a bug fix, feature request, or enhancement? [Bug Fix]

Summary by CodeRabbit

  • Documentation
    • Added clarification on tradability restrictions for Prime items and trading behavior for components.

@Clarity-89 Clarity-89 requested a review from a team as a code owner February 12, 2026 10:26
@Clarity-89 Clarity-89 requested a review from TobiTenno February 12, 2026 10:26
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Feb 12, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 65ee608 and 48eb63b.

📒 Files selected for processing (1)
  • build/tradable.mjs

📝 Walkthrough

Walkthrough

A documentation block is added to build/tradable.mjs clarifying that built Prime items cannot be marked tradable—only their components are—and that configuration overrides defined in config/overrides.json are applied separately.

Changes

Cohort / File(s) Summary
Documentation Enhancement
build/tradable.mjs
Added 16 lines of documentation clarifying Prime item tradeability restrictions and override configuration behavior, with no changes to underlying logic.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

📖 A note so clear, the Prime items sing,
"We're built to stay, not trade our wing!"
But our parts may roam, the config knows best,
Where overrides rest, put clarity to test. 🐰✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding documentation to explain the component check in tradable status logic.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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.

@TobiTenno TobiTenno enabled auto-merge (squash) February 13, 2026 21:45
@Clarity-89 Clarity-89 changed the title fix(tradable): use component check docs(tradable): explain component check Feb 14, 2026
…items

The tradableConditions function was blocking all Prime items with
weapon/warframe types (Rifle, Pistol, Melee, Warframe, etc.), making
148 Prime items incorrectly untradable. Most of these (143) have
tradable components and represent tradable sets.

Replace the blanket block with a three-layer approach:
1. Explicit override map for edge cases (Baro weapons, quest-locked items)
2. Component-based detection as the default fallback
3. Items with no tradable components remain untradable (Founders items)

Also simplifies the Wraith regex from Wraith\w|\wWraith to just Wraith,
which properly matches item names with spaces (e.g. "Strun Wraith").

Adds 25 unit tests for the tradable function covering all cases.
Update JSDoc to use plain Object types instead of import() syntax
to satisfy valid-jsdoc rule. Remove Wraith name-match test that was
left over after reverting the Wraith regex change.
Revert component-check approach per review feedback. Built Prime items
are not directly tradable; only their parts are. Components get their
own tradable flag. To determine if a Prime set is tradable, check
item.components for parts with tradable: true.
@TobiTenno TobiTenno merged commit 5987608 into WFCD:master Feb 23, 2026
10 checks passed
@wfcd-bot-boi
Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 1.1272.123 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants