Setting up PyImageJ without internet access
- Dominant language
- Python
- Stars
- 534
- Forks
- 95
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
I'm trying to set up PyImageJ to run on a server without internet access. I installed with conda and followed the instructions [here](https://github.com/imagej/pyimagej/blob/1.2.1/doc/Troubleshooting.md#debugging-tips:~:text=Initialize%20with%20a,standard%20Fiji%20distribution.) But when I [test my installation](https://github.com/imagej/pyimagej/blob/1.2.1/doc/Install.md#:~:text=Testing%20your%20installation) I get the following error
`Failed to bootstrap the artifact.
Possible solutions:
* Double check the endpoint for correctness (https://search.maven.org/).
* Add needed repositories to ~/.jgorc [repositories] block (see README).
* Try with an explicit version number (release metadata might be wrong).
Full Maven error output:
[ERROR] [ERROR] Some problems were encountered while processing the POMs:
[ERROR] Non-resolvable import POM: The following artifacts could not be resolved: net.imagej:imagej:pom:2.3.0 (absent): Could not transfer artifact net.imagej:imagej:pom:2.3.0 from/to scijava.public (https://maven.scijava.org/content/groups/public): Connect to maven.scijava.org:443 [maven.scijava.org/144.92.48.199] failed: connect timed out @ line 8, column 29
[ERROR] 'dependencies.dependency.version' for net.imagej:imagej-legacy:jar is missing. @ line 10, column 252
[ERROR] 'dependencies.dependency.version' for org.scijava:scijava-config:jar is missing. @ line 10, column 462
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR] The project net.imagej-BOOTSTRAPPER:imagej-BOOTSTRAPPER:0 (/home/kschmidt/.jgo/net.imagej/imagej/2.3.0/96c7e6a6707857e3645e206740265f7cd7cb8259fa4e6088027a50d0c8d21865/pom.xml) has 3 errors
[ERROR] Non-resolvable import POM: The following artifacts could not be resolved: net.imagej:imagej:pom:2.3.0 (absent): Could not transfer artifact net.imagej:imagej:pom:2.3.0 from/to scijava.public (https://maven.scijava.org/content/groups/public): Connect to maven.scijava.org:443 [maven.scijava.org/144.92.48.199] failed: connect timed out @ line 8, column 29 -> [Help 2]
[ERROR] 'dependencies.dependency.version' for net.imagej:imagej-legacy:jar is missing. @ line 10, column 252
[ERROR] 'dependencies.dependency.version' for org.scijava:scijava-config:jar is missing. @ line 10, column 462
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
***Invalid Initialization: you may be using a primary endpoint that lacks pom-scijava as a parent***
To keep all Java components at compatible versions we recommend using a primary endpoint with a pom-scijava parent.
For example, by putting 'net.imagej:imagej' first in your list of endpoints.
If you are sure you DO NOT want a primary endpoint with a pom-scijava parent, please re-initialize with 'add_legacy=False'.
Traceback (most recent call last):
File "", line 1, in
File "/home/kschmidt/miniconda3/envs/gable/lib/python3.10/site-packages/imagej/__init__.py", line 1202, in init
raise RuntimeError("Failed to create a JVM with the requested environment.")
RuntimeError: Failed to create a JVM with the requested environment.
`
I ran the PyImageJ doctor and get the response `Great job! All looks good.
`
What else do I need to do to get PyImageJ running without exposing my server to internet?
Contributor guide
No contributing guide indexed for this repository
Research direction
Review the offline setup described in doc/Install.md and doc/Troubleshooting.md, then trace the imagej.init call and its Maven bootstrap output. Reproduce the conda installation with network access disabled and determine what setup is required for initialization to complete without contacting maven.scijava.org.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, python
- Domain
- developer-experience, tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100