Repository navigation
feat: per-type return rates and return what was actually used - #26
Conversation
Each item type now has its own ratio under return_rates in config.yml (advanced_crafting, alloy_scrap, magic_gear, guns, goldsmith_jewelry, recipes), clamped to 0.0-1.0. The old max_return_rate/scrap_return_rate keys still apply when an entry is missing. Magic weapons, guns and goldsmithing jewelry now return the materials their plugin recorded as used at craft time (Magic 0.4.6, GunsAndGadgets 2.0.6, GemInfusion 2.2.5) instead of today's part costs or the project recipe. Items crafted before those versions are not recyclable. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review. 📝 WalkthroughWalkthroughRecycling providers now use recorded crafting materials for supported items. Return rates are configurable by item category, with legacy configuration fallbacks. The configured versions of GemInfusion, GunsAndGadgets, and Magic also changed. ChangesRecycling behavior and configuration
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Feature Merge Risk: ⚪ Minimal · up to No concrete merge-blocking issue was identified. Normal build checks should confirm the pinned dependencies, and deployment should include the compatible plugin jars together. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The recycling controls examined remain in place, and no introduced security vulnerability was established. Remaining risk concerns validation of the companion plugins’ recorded-material contracts and deployment of compatible versions together. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 12.50% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 40 functions across 14 files. (1 skipped: 1 unsupported.)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
I’m a rabbit with a crafting plan, Comment |
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Summary
Per-type return rates. Every item type Recycler handles now has its own ratio in
config.yml, likescrap_return_ratealready did:Values are clamped to 0.0-1.0 (non-finite values use the default). A missing entry falls back to the old
max_return_rate(crafted items) orscrap_return_rate(scrap), so an existing server config keeps its current behaviour untilreturn_ratesis added.RecycleProvider.returnRate()is now required per provider;appliesMaxReturnRate()is gone.Return what was actually used. Previously:
Now those three providers read the materials their plugin recorded at craft time:
GoldsmithProvenance.read(feat: record the materials each jewelry piece was made from GemInfusion#29)GunCraftInputs.readFrom(feat: record the materials each gun was crafted from GunsAndGadgets#27)GearProvenance.readInputs(feat: record the materials each mage weapon was crafted from Magic#36)Items crafted before those versions have no record and are refused (same approach as pre-2.2.0 scrap). AdvancedCrafting gear already records its deposited inputs and is unchanged.
Pins bump to GemInfusion 2.2.5, GunsAndGadgets 2.0.6 and Magic 0.4.7. CI needs those releases first; ship the four jars together.
Testing
mvn verifypasses locally with the 100% coverage gate (built against the three branches installed locally under the new versions).🤖 Generated with Claude Code
Summary by CodeRabbit