Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

require("packages").resource does not work in a sandbox #80

Open
kriszyp opened this issue Dec 5, 2009 · 1 comment
Open

require("packages").resource does not work in a sandbox #80

kriszyp opened this issue Dec 5, 2009 · 1 comment

Comments

@kriszyp
Copy link

kriszyp commented Dec 5, 2009

When I turn Jack's reloader functionality on, I get this error when I call the resource function in the packages module:
TypeError: Cannot read property "length" from undefined
at C:\dev\narwhal\lib\packages.js:9

@kriszyp
Copy link
Author

kriszyp commented Dec 5, 2009

I guess basically the issue is that some modules expect to really be singletons. Another module that behaves poorly when instantiated multiple times (as the reloader does) is the event-queue. Perhaps we need to include the modules option in the reloader middleware that includes "packages" and "event-queue" modules... But this certainly doesn't seem very scalable, it would be nice to be able to smarter selection of which modules get reloaded, like be able to have a sandbox that only reloads modules from a certain package (or packages).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant