NOTICE! This is a static HTML version of a legacy Fiji BugZilla bug.

The Fiji project now uses GitHub Issues for issue tracking.

Please file all new issues there.

Bug 455 - Plugin upload fails
Plugin upload fails
Status: RESOLVED WORKSFORME
Product: Fiji
Classification: Unclassified
Component: Plugins
unspecified
PC All
: P2 normal
Assigned To: ImageJ Bugs Mailing List
Depends on:
Blocks:
 
Reported: 2012-07-25 20:13 CDT by Gavin
Modified: 2012-09-18 20:32 CDT
1 user (show)

See Also:

Description Gavin 2012-07-25 20:13:09 CDT
I just updated the Fiji Updater today. When uploading a plugin to my plugin site on Windows or Linux/CentOS, after the dependencies resolution dialog box is closed, I get the following error: "Could not upload: possibly unknown protocol." There's nothing interesting in the log when debug mode is on, nor is there anything interesting in the console.

I tried to revert to the previous updater to test if the behavior was solely in the updater, but Fiji forces me to install the new updater if I want to open the updater. AFAICT I can't use the previous version.
Comment 1 Johannes Schindelin 2012-07-25 22:15:10 CDT
Yes, the old version is unsupported, so you cannot downgrade.

Having said that, I just uploaded a new version, could you test again after an update? (The bug was reported to me already, via private mail, probably so that nobody would be able to know that I am working on it already, or maybe by mistake.)
Comment 2 Gavin 2012-07-26 05:36:51 CDT
Sorry, was away from my system until now.

I received the new updater but unfortunately on Windows the behavior is the same as before. I can't check Linux until tomorrow morning as my install is running a long job and I don't want to disturb it.

Addendum - when I look at the time stamp on the updater jar it's still the same time stamp as the update this morning. So apparently the update didn't work. However, when I restart Fiji it no longer asks to update the updater.
Comment 3 Gavin 2012-07-26 20:20:00 CDT
I just reverted both the Linux and Win updaters to the old version and ran Help>Update Fiji. This time, based on the updater jar timestamp, the updater update worked. The behavior is the same as originally described on both platforms, except that on Linux the error occurs immediately after clicking 'upload to server' rather than after the dependencies dialog box (it might have been this way originally TBH; I can't quite remember). 

However, on Linux I now get this stack trace in the console:

bash-4.1$ java.lang.InstantiationException: No uploader found for protocol ssh
        at imagej.updater.core.FilesUploader.getUploader(FilesUploader.java:88)
        at imagej.updater.core.FilesUploader.<init>(FilesUploader.java:100)
        at imagej.updater.gui.UpdaterFrame.upload(UpdaterFrame.java:794)
        at imagej.updater.gui.UpdaterFrame$6$1.run(UpdaterFrame.java:323)
Comment 4 Johannes Schindelin 2012-07-27 23:56:46 CDT
This is most likely due to jars/ij-updater-ssh-2.0.0-SNAPSHOT.jar not being installed.

To help things, I taught the Updater to detect that situation and special-case when you lack the ssh uploader (just because it used to be the default uploader in the Fiji Updater).

Could you please test again, after an update?
Comment 5 Gavin 2012-07-28 06:11:51 CDT
I'm afraid the behavior is the same as before, although the stack trace line numbers are different:

java.lang.InstantiationException: No uploader found for protocol ssh
        at imagej.updater.core.FilesUploader.getUploader(FilesUploader.java:94)
        at imagej.updater.core.FilesUploader.<init>(FilesUploader.java:106)
        at imagej.updater.gui.UpdaterFrame.upload(UpdaterFrame.java:794)
        at imagej.updater.gui.UpdaterFrame$6$1.run(UpdaterFrame.java:323)

Additionally, the first attempts to install the new updater failed on Windows and Linux judged by the time stamps. I again reverted the loaders to older versions and the updater was able to update.

That being said - if the error is because the updater now has dependencies, perhaps I should just not be an idiot and download those dependencies? Or do you want to actually squash this bug? Whichever route you prefer is fine with me but if the bug is because my install isn't up to date I'm not sure it's a good use of your time. I should have reported that I hadn't updated recently but I thought that wouldn't affect the updater - sorry.

Comment 6 Johannes Schindelin 2012-07-30 20:17:38 CDT
The updater has dependencies, all of which should be installed by default: ij-core, ij-updater-core, log4j, slf4j-api and slf4j-log4j12. All of those should be in the jars/ sub-directory of Fiji.app/.

Note that ij-updater-ssh is *not* a dependency of ij-updater-core and neither of the updater (ij-ui-swing-updater).

The current version of ij-ui-swing-updater (which should be exactly 113424 bytes) was able -- at least in my tests -- to detect that ij-updater-ssh was missing and tried to download & install it, falling back to erroring out mentioning that the protocol 'ssh' was not supported by any local uploader component.
Comment 7 Gavin 2012-08-01 18:24:12 CDT
All the files you mention are installed in both win and linux. The updater is not asking to update itself. ij-ui-swing-updater.jar, in both cases, is 105123 bytes with a md5 of 170222bdc84691b5e8def827c32a62ad, so it looks as if for some reason the updater version is not the most recent.

There is new behavior, however: On windows, when trying to upload my plugin, I get the following dependencies dialog:

Conflict: plugins/Skeletonize3D_.jar
Is locally modified but a dependency of

plugins/myplugin.jar

Conflict: jars/ij.jar
Is locally modified but a dependency of

plugins/myplugin.jar

Conflict: jars/ij-updater-core-2.0.0-SNAPSHOT.jar
Depends on jars/sezpoz-1.9.jar which was not uploaded.

Conflict: jars/ij-core-2.0.0-SNAPSHOT.jar
Depends on jars/sezpoz-1.9.jar which was not uploaded.

Conflict: jars/ij-ui-swing-base-2.0.0-SNAPSHOT.jar
Depends on jars/sezpoz-1.9.jar which was not uploaded.

Conflict: jars/netcdf-java-4.0.41.jar
Depends on plugins/visad-lite-2.0.20070828.jar which was not uploaded.

The first two I can dismiss by choosing not to upload the jars (I didn't modify them, btw, so I don't know why they're showing up as such. Also, this behavior was present in older uploaders). The last four are new with this uploader and only have the option to break the dependency. However, clicking that button does nothing AFAICT, and I can't proceed further.

On Linux, only the last Conflict message occurs, but the results are the same: clicking the break dependency button doesn't appear to do anything and I can't proceed. 
Comment 8 Johannes Schindelin 2012-08-02 20:49:46 CDT
Thanks for your patience. I identified the problem with sezpoz, it was forgotten due to a bug in a previous version of the updater. That problem should be fixed now.
Comment 9 Gavin 2012-08-02 22:23:55 CDT
I got the latest version of the updater and the sezpoz related items no longer show up. However, this line:

Conflict: jars/netcdf-java-4.0.41.jar
Depends on plugins/visad-lite-2.0.20070828.jar which was not uploaded.

...still appears in the dependencies dialog for the uploader and blocks uploading as previously described.

Also, when running the updater on linux, the following output/exceptions show up in the terminal. The 'shadow' output occurred on load. The first exception occurred when updating the updater. The second occurred when the new updater was started for the first time.
              
bash-4.1$ fiji/Fiji.app/fiji-linux64                             
'jars/javassist.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                          
'jars/jsch.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                               
'jars/jfreechart.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                         
'jars/imglib2-algorithms.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                 
'jars/ij.jar' from update site 'Fiji' shadows the one from update site 'ImageJ' 
'jars/imglib2-io.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                         
'jars/clibwrapper_jiio.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                   
'jars/imglib2.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                            
'jars/jcommon.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                            
'Contents/MacOS/ImageJ-macosx' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                
'Contents/MacOS/ImageJ-tiger' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                 
'ImageJ-linux32' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                              
'ImageJ-linux64' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                              
'ImageJ-win32.exe' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                            
'ImageJ-win64.exe' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                            
'jars/ij-launcher.jar' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                        
'images/icon.png' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                             
'images/icon-flat.png' from update site 'Fiji' shadows the one from update site 'ImageJ'                                                                        
Trying to install and execute the new updater                                   
java.lang.ClassNotFoundException: imagej.updater.gui.ImageJUpdater                                             
        at java.net.URLClassLoader$1.run(URLClassLoader.java:202)                                              
        at java.security.AccessController.doPrivileged(Native Method)                                          
        at java.net.URLClassLoader.findClass(URLClassLoader.java:190)                                          
        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)                                               
        at java.lang.ClassLoader.loadClass(ClassLoader.java:248)                                               
        at imagej.updater.gui.ImageJUpdater.run(ImageJUpdater.java:183)                                        
        at fiji.updater.Adapter.runUpdater(Adapter.java:160)                                                   
        at fiji.updater.Adapter.showDialog(Adapter.java:109)
        at fiji.updater.Adapter.checkOrShowDialog(Adapter.java:87)
        at fiji.updater.Updater.run(Updater.java:14)
        at fiji.updater.UptodateCheck.run(UptodateCheck.java:8)
        at fiji.Main.gentlyRunPlugIn(Main.java:308)
        at fiji.Main.runUpdater(Main.java:299)
        at fiji.Main$1.run(Main.java:346)
bash-4.1$ fiji/Fiji.app/fiji-linux64
Exception in thread "AWT-EventQueue-0" java.lang.IndexOutOfBoundsException: Index: 19, Size: 29
        at java.util.ArrayList.RangeCheck(ArrayList.java:547)
        at java.util.ArrayList.get(ArrayList.java:322)
        at imagej.updater.gui.FileTable$FileTableModel.getValueAt(FileTable.java:378)
        at javax.swing.JTable.getValueAt(JTable.java:2686)
        at javax.swing.JTable.prepareRenderer(JTable.java:5703)
        at javax.swing.plaf.basic.BasicTableUI.paintCell(BasicTableUI.java:2072)
        at javax.swing.plaf.basic.BasicTableUI.paintCells(BasicTableUI.java:1974)
        at javax.swing.plaf.basic.BasicTableUI.paint(BasicTableUI.java:1770)
        at javax.swing.plaf.ComponentUI.update(ComponentUI.java:143)
        at javax.swing.JComponent.paintComponent(JComponent.java:752)
        at javax.swing.JComponent.paint(JComponent.java:1029)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paint(JComponent.java:1038)
        at javax.swing.JViewport.paint(JViewport.java:747)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paint(JComponent.java:1038)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paint(JComponent.java:1038)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paint(JComponent.java:1038)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paint(JComponent.java:1038)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paint(JComponent.java:1038)
        at javax.swing.JLayeredPane.paint(JLayeredPane.java:567)
        at javax.swing.JComponent.paintChildren(JComponent.java:862)
        at javax.swing.JComponent.paintToOffscreen(JComponent.java:5131)
        at javax.swing.BufferStrategyPaintManager.paint(BufferStrategyPaintManager.java:278)
        at javax.swing.RepaintManager.paint(RepaintManager.java:1224)
        at javax.swing.JComponent.paint(JComponent.java:1015)
        at java.awt.GraphicsCallback$PaintCallback.run(GraphicsCallback.java:21)
        at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:60)
        at sun.awt.SunGraphicsCallback.runComponents(SunGraphicsCallback.java:97)
        at java.awt.Container.paint(Container.java:1780)
        at java.awt.Window.paint(Window.java:3375)
        at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:796)
        at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:713)
        at javax.swing.RepaintManager.seqPaintDirtyRegions(RepaintManager.java:693)
        at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:125)
        at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:642)
        at java.awt.EventQueue.access$000(EventQueue.java:85)
        at java.awt.EventQueue$1.run(EventQueue.java:603)
        at java.awt.EventQueue$1.run(EventQueue.java:601)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:612)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
bash-4.1$ 

Comment 10 Johannes Schindelin 2012-08-02 22:56:16 CDT
Have you seen some console output like "found class ... which is in the following files: ..netcdf-java.jar ...visad-lite.jar...; adding both"?

If that is the case, you should be able to edit the list of dependencies manually by clicking on the plugin incurring the visad-lite dependency and then deleting that dependency in the details view.

As to the two exceptions: the first should be accompanied by an error message that says: please restart Fiji and call Help>Update Fiji. The second exception is something that happens here, too, occasionally. But a restart usually makes it go away, so it is really hard to reproduce and therefore to fix.
Comment 11 Gavin 2012-08-02 23:11:08 CDT
>Have you seen some console output like "found class ... which is in the
>following files: ..netcdf-java.jar ...visad-lite.jar...; adding both"?

Unfortunately no. The output I pasted in my PP was the entirety of the output from starting Fiji & the updater and exiting both twice.

>As to the two exceptions: the first should be accompanied by an error message
>that says: please restart Fiji and call Help>Update Fiji.

Yes, that is what I saw.
Comment 12 Johannes Schindelin 2012-08-02 23:24:08 CDT
You could still try to remove the visad-lite dependency manually as I described.

As to the restart: have you tried that? Does the IndexOutOfBoundsException occur reliably?
Comment 13 Gavin 2012-08-02 23:51:09 CDT
>You could still try to remove the visad-lite dependency manually as I
>described.

Sorry, I took your post to mean that only if I saw the text you described in the console could I attempt to remove the dependency manually.

However, clicking in the details window for netcdf doesn't appear to give me any way to modify the dependencies. The best I can do is highlight things - there's no cursor, the delete and backspace buttons don't do anything, and the right mouse button doesn't do anything.

If it helps at all, the netcdf jar is not installed according to the updater.

>As to the restart: have you tried that? Does the IndexOutOfBoundsException
>occur reliably?

3/10 start/stop cycles resulted in the error on start of the updater.
Comment 14 Johannes Schindelin 2012-08-06 22:26:17 CDT
Because I am curious: do you know where you got that visad-lite .jar file from?

In any case, the visad-lite issue should be gone, can you confirm?
Comment 15 Curtis Rueden 2012-08-06 22:39:00 CDT
> Because I am curious: do you know where you got that visad-lite .jar file from?

The visad-lite.jar is part of the LOCI Fiji update site. It is a dependency of the "VisBio Fiji plugins" (http://loci.wisc.edu/software/visbio-fiji-plugins).
Comment 16 Curtis Rueden 2012-08-06 22:40:00 CDT
The code for the VisBio Fiji plugins, by the way, is at:

    https://github.com/uw-loci/visbio-imagej/

If you look in the pom.xml you'll see the visad-lite dependency.
Comment 17 Gavin 2012-08-06 22:54:20 CDT
>Because I am curious: do you know where you got that visad-lite .jar file from?

I didn't, in fact - neither it nor the netcdf jars exist in either my win or linux installs.

>In any case, the visad-lite issue should be gone, can you confirm?

Yes, I can now break the dependency between netcdf and visad (neither of which actually exist). 

However, the original issue is back again - after the dependencies dialog is closed, an error dialog pops up with 'Could not upload (possibly unknown protocol)' and on linux the following stacktrace is thrown:

java.lang.InstantiationException: No uploader found for protocol ssh
        at imagej.updater.core.FilesUploader.getUploader(FilesUploader.java:94)
        at imagej.updater.core.FilesUploader.<init>(FilesUploader.java:106)
        at imagej.updater.gui.UpdaterFrame.upload(UpdaterFrame.java:794)
        at imagej.updater.gui.UpdaterFrame$6$1.run(UpdaterFrame.java:323)
Comment 18 Johannes Schindelin 2012-09-04 21:59:52 CDT
Sorry for the long delay, I just forgot to update this issue: it should be fixed now (after updating Fiji_Updater.jar and making sure that ij-updater-ssh is up-to-date).