Skip to content

Fix Item granted skills not showing up as Implicits when pasting#1873

Merged
LocalIdentity merged 1 commit into
PathOfBuildingCommunity:devfrom
unrealdreamz:fix/pasted-granted-skill-implicit
May 19, 2026
Merged

Fix Item granted skills not showing up as Implicits when pasting#1873
LocalIdentity merged 1 commit into
PathOfBuildingCommunity:devfrom
unrealdreamz:fix/pasted-granted-skill-implicit

Conversation

@unrealdreamz
Copy link
Copy Markdown
Contributor

@unrealdreamz unrealdreamz commented May 18, 2026

Summary

  • Keep pasted base-granted skill lines implicit when they appear after an implicit separator.
  • Add a regression using the reported spear paste text.

Root Cause

  • Imported items already know that some base implicits grant skills.
  • Pasted item parsing could leave the implicit section after a separator and then treat Grants Skill: ... as a normal explicit/unknown line.
  • For spear bases, that meant Grants Skill: Spear Throw could be misclassified instead of detected as the base-granted skill.

Fix

  • Add a small base-implicit line helper for raw item parsing.
  • When parsing pasted game text, preserve a line as implicit if it exactly matches an implicit line on the resolved item base.
  • Do not force such base-implicit lines into explicit mod handling.
  • Preserve the following explicit mods normally.

Validation

  • PASS: git diff --check
    • Output only included line-ending warnings from the Windows checkout.
  • PASS: Lua syntax check for the touched files using lupa.
  • PASS: targeted Busted spec after installing the repo's LuaJIT/Busted dependencies locally:
    • Command: busted --lua=luajit ../spec/System/TestItemParse_spec.lua
    • Output: 25 successes / 0 failures / 0 errors / 0 pending : 0.329 seconds
  • Not run locally: docker-compose up
    • Docker/docker-compose are not available in this local environment.
  • ModCache regeneration: not applicable; this PR does not change mod parsing.

Risk / Rollback

  • Low risk: the special handling only applies when a pasted line exactly matches the resolved base implicit.
  • Explicit mods following the granted skill remain explicit and are covered by the regression.
  • Rollback is the parser helper/branch plus the test.

Fixes #1728

@unrealdreamz unrealdreamz marked this pull request as ready for review May 18, 2026 18:38
@LocalIdentity LocalIdentity added the bug: accuracy Wording differences label May 19, 2026
@LocalIdentity LocalIdentity changed the title Keep pasted base granted skills implicit Fix Item granted skills not showing up as Implicits when pasting May 19, 2026
@LocalIdentity LocalIdentity merged commit f860ca5 into PathOfBuildingCommunity:dev May 19, 2026
2 of 3 checks passed
LocalIdentity pushed a commit that referenced this pull request May 20, 2026
@cbui
Copy link
Copy Markdown

cbui commented May 23, 2026

image

I think this commit breaks the implicit parsing and the slider for the item. It keeps appending the implicit over and over.

@LocalIdentity @unrealdreamz

@LocalIdentity
Copy link
Copy Markdown
Contributor

LocalIdentity commented May 23, 2026

@cbui I need steps for how you encountered that bug
Just figured it out

@LocalIdentity
Copy link
Copy Markdown
Contributor

@cbui now fixed on dev. Thanks for letting me know

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

Labels

bug: accuracy Wording differences

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Granted Skills not counting as implicit when pasting item

3 participants