Skip to content

Conversation

@rwtolbert
Copy link
Contributor

Summary: In a previous PR #230, in an attempt to get tests working where packages were being installed into the original syspath instead of a test-local syspath, I removed some code that "fixed" the test but broke binscripts more generally.

binscripts are set up with a dynamic syspath hardcoded at the beginning and removed at the end to make sure they can find their dependencies, regardless of JANET_PATH.

This restores that behavior. The tests were originally failing since they were running janet-pm via sh/exec AND janet-pm didn't know about the custom JANET_PATH.

So the second change here, just to the tests, is to set JANET_PATH to the test-local syspath before running janet-pm via sh/exec

This should also address the problem seen in #248, where janet-pm fails after activating a new env

Summary: In a previous PR, in an attempt to get tests working where
packages were being installed into the original syspath instead of a
test-local syspath, I removed some code that "fixed" the test but
broke binscripts more generally.

binscripts are set up with a dynamic syspath hardcoded at the beginning
and removed at the end to make sure they can find their dependencies,
regardless of JANET_PATH.

This restores that behavior. The tests were originally failing since
they were running `janet-pm` via `sh/exec` AND `janet-pm` didn't know
about the custom JANET_PATH.

So the second change here, just to the tests, is to set JANET_PATH
to the test-local syspath before running `janet-pm` via `sh/exec`

This should also fix the problem seen in janet-lang#248, where `janet-pm`
fails after activating a new `env`
@bakpakin bakpakin merged commit ac292ba into janet-lang:master Oct 5, 2025
23 checks passed
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.

2 participants