Repository navigation
fix: use relative paths inside pip package (drop ../furniture_sim/ prefix) - #1
Merged
Merged
Conversation
…efix) All XML files referenced assets via ../furniture_sim/X paths. When installed as a pip package the sibling furniture_sim/ directory does not exist. Fix by making paths relative to each file's actual location: - Top-level *.xml (e.g. bin.xml): ../furniture_sim/X → X - Sub-directory */*.xml (e.g. bin/bin_asset.xml): ../furniture_sim/X → ../X - kitchen/*.xml use ../../furniture_sim/X → ../X (two-level-up pattern) Fixes path resolution when furniture_sim is imported from a virtual environment without a git-submodule checkout of the full repo tree.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
All XML files reference assets via
../furniture_sim/Xpaths. When installed as a pip package, the siblingfurniture_sim/directory does not exist — MuJoCo cannot resolve these paths and asset loading fails at runtime.Fix
Make paths relative to each file's actual location within the package:
*.xml../furniture_sim/XX*/*.xml../furniture_sim/X../Xkitchen/*.xml../../furniture_sim/X../XImpact
This is required for
furniture_simto work when installed via pip without a full git-submodule checkout. Without this fix, downstream consumers (e.g. MyoSuite) must apply runtime XML patching to rewrite these paths on every model load.