-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Load tarball - IPM look for dependency from repo instead #721
Comments
Minimum reproducible example/tmp/load-export-deps/module.xml <?xml version="1.0" encoding="UTF-8"?>
<Export generator="Cache" version="25">
<Document name="load-export-deps.ZPM">
<Module>
<Name>load-export-deps</Name>
<Version>0.0.1</Version>
<Packaging>module</Packaging>
</Module>
</Document>
</Export> /tmp/load-export/module.xml <?xml version="1.0" encoding="UTF-8"?>
<Export generator="Cache" version="25">
<Document name="load-export.ZPM">
<Module>
<Name>load-export</Name>
<Version>0.0.1</Version>
<Packaging>module</Packaging>
<Dependencies>
<ModuleReference>
<Name>load-export-deps</Name>
<Version>0.0.1</Version>
</ModuleReference>
</Dependencies>
</Module>
</Document>
</Export> Then run, zpm "repo -fs -name local -path /tmp"
zpm "install load-export"
zpm "load-export package -export-deps 1 -DPath=/tmp/package -v"
zpm "repo -delete-all"
zpm "uninstall load-export-deps"
zpm "uninstall load-export"
zpm "load /tmp/package.tgz"
Also verified that @isc-tleavitt Has this worked before in IPM v0.7? It's strange that such a problem has gone unnoticed for so long. |
@jinlouISC A v0.10.0-beta.12 release artifact is triggered by merging #726 should be generated in a few minutes. Can you try that and verify this bug is fixed? |
@isc-shuliu thank you for letting me know, yes will do and will keep you updated! |
I tested on v0.10.0-beta.12 where IPM was able to locate the dependencies in the tarball. But I ran into another issue where repository 'ipm-temp-dot-modules-1' is not being created, so none of the dependencies were installed because IPM shell would complain "ERROR! Repository 'ipm-temp-dot-modules-1' is unavailable." |
@isc-shuliu @jinlouISC I was not able to reproduce this error with a smaller module with dependencies. Environment:
Windows OS. Steps:
HSLIB> zpm 0.9.0+snapshot (DeveloperMode)
|
After debugging with @isc-eneil and @jinlouISC, it turns out to be a macOS specific issue (doesn't impact docker containers on macOS). When using work queue manager to load dependencies in other processes, the call to The quickest workaround is to support loading with single processing (by setting pSynchronous to 1) in |
This may very well be related to #736 (comment), since both Jin and I also use multiprocessing (which according to Tim, runs as This can well explain the |
@isc-shuliu @isc-eneil I think that is a good theory, and I gave it a try on this instance whose owner is A good finding is that the 3 flags mentioned in #717 |
I'm not sure about |
Hi @isc-shuliu ! Thank you for putting in the fix. To load module synchronously on macOS with this change, would the command just be zpm "load package-name -synchronous"? Thanks in advance! |
Yes, exactly. And it works for other platforms as well (although macOS seems to be the only platform that needs synchronous loading to avoid the bug). |
Environment:
IPM v0.10.beta-4 on an I4H instance with no repo configured.
Background:
The module has dependencies. The tarball includes all the dependency modules.
Behavior:
When I do zpm "load ", it stopped at the first dependency hs.rest, "Could not find satisfactory version of hs.rest in any repositories. Required by: healthshare.hp.pas: ^2.1.0". I think it is looking for the dependency from the repository, not from the tarball.
In contrast, on a instance with a repo configured, when I load the tarball, IPM would install the dependencies from the repo, not from the tarball.
@isc-shuliu
The text was updated successfully, but these errors were encountered: