Skip to content

Fix InventoryType wire values - #173

Merged
cinderblocks merged 1 commit into
cinderblocks:masterfrom
lyrae-versebound:lyrae/EXP-003-issue-170
Aug 13, 2026
Merged

Fix InventoryType wire values#173
cinderblocks merged 1 commit into
cinderblocks:masterfrom
lyrae-versebound:lyrae/EXP-003-issue-170

Conversation

@lyrae-versebound

Copy link
Copy Markdown
Contributor

Description

Align the public InventoryType tail with the current Second Life wire values and extend the existing type-name table through GLTF binary assets.

The corrected assignments are:

  • Widget = 23
  • Person = 24
  • Settings = 25
  • Material = 26
  • GLTF = 27
  • GLTFBin = 28

This intentionally corrects the existing public numeric values for Settings (23 to 25) and Material (24 to 26). Consumers compiled against the old constants should rebuild against the corrected enum.

The values and wire names are based on the authoritative Second Life Viewer definitions in llinventorytype.h and llinventorytype.cpp.

Testing

  • Added deterministic coverage for numeric values, enum names, and string round trips for values 23–28.
  • Added a regression test proving incoming wire value 26 creates InventoryMaterial.
  • Focused regression: 7/7 passed after the fix; the same cases failed before it.
  • Neighboring InventoryManagerTests: 10/10 passed.
  • LibreMetaverse.Types net10.0 Release build: succeeded with no warnings or errors.

The broader net10.0 test run is not completely green: 7 existing HttpListener-based tests fail on this Windows environment with error code 6. The identical seven failures reproduce on the untouched base revision, while the candidate adds seven passing tests, so those failures are unrelated to this change.

No live Agni validation was performed.

Fixes #170

Copilot AI 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.

Pull request overview

Aligns InventoryType values and wire names with current Second Life definitions.

Changes:

  • Corrects and extends enum values 23–28.
  • Adds corresponding wire-name conversions.
  • Adds regression tests for mappings and material creation.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
LibreMetaverse.Types/UtilsConversions.cs Extends inventory wire-name mappings.
LibreMetaverse.Types/Enums.cs Corrects and adds inventory enum values.
LibreMetaverse.Tests/InventoryManagerTests.cs Tests mappings and material instantiation.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@cinderblocks
cinderblocks marked this pull request as ready for review August 13, 2026 13:54
@cinderblocks
cinderblocks merged commit 08c9743 into cinderblocks:master Aug 13, 2026
12 checks passed
@cinderblocks

Copy link
Copy Markdown
Owner

Thanks!

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.

InventoryType.Material is the wrong value — real materials come back as an un-nameable 26

3 participants