Closed joshmoore closed 4 years ago
cc: @sukunis
I'll open a PR next about ome/openmicroscopy with an integration test.
wrote a little python script to import a file
import omero.scripts
import omero.cli
cli = omero.cli.CLI()
cli.loadplugins()
c = omero.scripts.client("example.py")
cli._client = c.createClient(secure = True)
cli.invoke(["import", "/Users/jmarie/Desktop/s.png"])
ICE_CONFIG=ice.config python example.py
(doc from omero.scripts.client
the returned client is created via the empty constructor to omero.client using only --Ice.Config or ICE_CONFIG
)
The file imported correctlyWith https://github.com/ome/openmicroscopy/pull/6222 merged, shall we get this in?
Edit: actually, why is that passing in https://latest-ci.openmicroscopy.org/jenkins/job/OMERO-test-integration/286/ without this merged in?
STDOUT:
I am the script named 4c9a9167-77a8-4bf6-bcff-c1f63ac653d7
Session session-2db587a0-e1e0-4037-91a8-f17d3a86b6d0/22af84a3-e236-4bc4-a890-21fb3246647b -t -e 1.1 @ BlitzAdapters
Previously logged in to localhost:14064 as root
STDERR:
Active client found
stdin is not a terminal: cannot request server
!! 04/03/20 03:44:59.689 error: communicator not destroyed during global destruction.
Stricter tests now passing.
User-scripts should be able to simply create an omero.cli.CLI instance and perform operations w/o needing to re-login. For import, this requires passing the
omero.host
property setting.see: https://lists.openmicroscopy.org.uk/pipermail/ome-users/2014-September/004783.html