This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 182522 - Improper dependencies in jackpot modules
Summary: Improper dependencies in jackpot modules
Status: RESOLVED INVALID
Alias: None
Product: contrib
Classification: Unclassified
Component: Jackpot (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P3 normal (vote)
Assignee: Jan Lahoda
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-22 19:53 UTC by err
Modified: 2010-04-27 18:37 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
plugin collection to reproduce problem (295.95 KB, application/octet-stream)
2010-03-23 00:39 UTC, err
Details

Note You need to log in before you can comment on or make changes to this bug.
Description err 2010-03-22 19:53:08 UTC
This is about more than being fastidious and saving disk space. After using the plugin manager to uninstall and remove some modules I had installed, I had to manually remove the files I found in these directories to get rid of some Menu items associated with the removed plugin.

Seems like the uninstall/reboot (also a var/cache cleanup) should have been enough to get rid of the menu-items. And certainly doing remove.

There is stuff left in
  - <udir>/update_tracking
  - <udir>/modules and possibley <udir>/modules/{ext,doc}
  - <udir>/config/Modules

there can also be stuff in config/Preferences/... but doesn't seem like this can be dealt with very easily

Product Version: NetBeans IDE Dev (Build 201003200200)
Java: 1.6.0_18; Java HotSpot(TM) Client VM 16.0-b13
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
Userdir: C:\Documents and Settings\erra\.netbeans\dev
Comment 1 err 2010-03-22 20:33:19 UTC
More info

Issue may be with plugins where only a few items show up in the installed plugins.

In this example I had removed two items from the Installed tab, after the IDE restart the Downloaded tab had 6 items that could be removed. Notice that in the following before/after the after has 6 fewer items.

I vaguely recall there is/was an option in the plugin manager that would present modules as a very long list and not filter stuff out. But I can't find it right now.

BEFORE UNINSTALL
/dev/ $ ls update_tracking/
org-netbeans-modules-jackpot30-api.xml
org-netbeans-modules-jackpot30-compiler.xml
org-netbeans-modules-jackpot30-file.xml
org-netbeans-modules-jackpot30-hintsimpl.xml
org-netbeans-modules-jackpot30-jackpot.xml
org-netbeans-modules-jackpot30-java-hints.xml
org-netbeans-modules-jackpot30-kit.xml
org-netbeans-modules-jackpot30-refactoring.xml
org-netbeans-modules-jackpot30-test-borrowed.xml
org-netbeans-modules-jackpot30-transformers.xml
org-netbeans-modules-jeriglib.xml

AFTER
/dev/ $ ls update_tracking/
org-netbeans-modules-jackpot30-api.xml
org-netbeans-modules-jackpot30-compiler.xml
org-netbeans-modules-jackpot30-jackpot.xml
org-netbeans-modules-jackpot30-java-hints.xml
org-netbeans-modules-jeriglib.xml
Comment 2 dlipin 2010-03-22 20:37:22 UTC
> There is stuff left in
>  - <udir>/update_tracking
>  - <udir>/modules and possibley <udir>/modules/{ext,doc}
>  - <udir>/config/Modules

Actually this should be removed. Do you have reproducible test case starting with clean userdir? Could you please specify steps to reproduce including:
1) which distribution do you use (javase/java/c++/ruby/all/...)?
2) do you use installer or zip?
3) which modules are you uninstalling?
Comment 3 err 2010-03-23 00:07:51 UTC
I attached the jackpot update directory, which I built this morning with source from http://bitbucket.org/jlahoda/jackpot30/.

1) which distribution do you use (javase/java/c++/ruby/all/...)?
2) do you use installer or zip?
3) which modules are you uninstalling?
Comment 4 err 2010-03-23 00:36:43 UTC
(oops, lets try that again)

I attached the jackpot update directory, which I built this morning with source from http://bitbucket.org/jlahoda/jackpot30/.



started NB with
    "C:\a\j\NetBeans Dev 201003200200\bin\netbeans.exe"
    --console new -J-Dnetbeans.logger.console=true
    -J-Dcom.raelity.jvi.DEBUG=true
    --userdir "C:/Documents and Settings/erra/.netbeans/TEST"
    
    did not import any settings

    Tools>Plugins>Downloaded>AddPlugins...
    navigate to directory holding .nbm files
                        Ctrl-A to select all the files, click open
    multiple select everything EXCEPT jacpot30-help.nbm
        there is a misshing help file so don't include it, avoid an exception,
        but it doesn't matter, it fails same either way
    Click Install, agree/continue to everything
                        -- note there is an exception during the install
                           since the help file is missing
                        ignore the exception hit finish, close
    This installs 11 modules

    Observe Menu>Refactor two new items: Apply Patterns, Global Find Dup

    restart the IDE just for the heck of it

    Tools>Plugins select
        - Jackpot 3.0 Refactoring Bridge
        - Jackpot 3.0
    Click Uninstall > Uninstall > Finish

    
    Observe after restart Menu>Refactor still has two plugin items
    and there is still stuff in the directories


> 1) which distribution do you use (javase/java/c++/ruby/all/...)?

javase

> 2) do you use installer or zip?

I used windows installer to install javase

> 3) which modules are you uninstalling?
Comment 5 err 2010-03-23 00:39:33 UTC
Created attachment 95572 [details]
plugin collection to reproduce problem
Comment 6 err 2010-03-23 00:43:59 UTC
In steps to reproduce ignore the lines which are shifted over to the right,
in particular ignore:

                        Ctrl-A to select all the files, click open
and
                        -- note there is an exception during the install
                           since the help file is missing
                        ignore the exception hit finish, close
Comment 7 err 2010-03-23 15:09:18 UTC
Question, after uninstall and restart IDE, what does "remove" do?
Comment 8 dlipin 2010-03-24 16:14:22 UTC
> after uninstall and restart IDE, what does "remove" do?

If we speak about plugin manager, then there is no such action. We have "Disable" (plugin is turned off but still present on disk) and "Uninstall" (which removes plugin the IDE and from disk drive as well.
Comment 9 err 2010-03-24 17:24:04 UTC
What I meant was after
    - uninstall
    - restart
    - Tools>Plugins>Downloaded>
I observe that the downloaded tab shows the stuff I just uninstalled and there is a remove button.
Comment 10 dlipin 2010-03-24 17:32:16 UTC
Remove button here just removes the selected plugin from this list (not from disk).
Comment 11 err 2010-03-24 17:44:41 UTC
So I guess the question is "where did the list come from" after I just uninstalled/restarted the plugin? I looked and there are no files on the disk, they were all properly removed (not like the plugin this bug refers to).

This could be a feature I guess, the last removed stuff, but there is no indication of where on disk it is looking (IIRC).
Comment 12 dlipin 2010-03-24 20:53:19 UTC
> So I guess the question is "where did the list come from" after I just
uninstalled/restarted the plugin? 

The list is created from the .nbm files which are available somewhere on your disk. The {update_tracking,modules,config/Modules} files are created after you install the module (from .nbm file) and deleted after your uninstall it. Installing and uninstalling plugin does not affect(delete/modify) .nbm file on disk. So after you uninstall plugin using Plugin Manager, the corresponding .nbm file(s) are likely still somewhere on disk and they are shown again in Downloaded tab as plugins available for installation.
Comment 13 dlipin 2010-03-26 20:47:40 UTC
I have checked the behavior you've described (install all .nbms from the attached archive except *help.nbm, then uninstall Jackpot 3.0 Refactoring Bridge and Jackpot 3.0) and confirm that after uninstallation the following modules are not uninstalled:
org-netbeans-modules-jackpot30-api
org-netbeans-modules-jackpot30-compiler
org-netbeans-modules-jackpot30-jackpot
org-netbeans-modules-jackpot30-java-hints
org-netbeans-modules-jeriglib

However it is likely the issue about module dependencies and eager/autoload statuses of the bunch of jackpot modules. Reassiging to jlahoda.

PS. Some suggestions/required checks can be found in Issue 170626.
Comment 14 Jesse Glick 2010-04-27 18:37:56 UTC
http://bitbucket.org/jlahoda/jackpot30/issues is the right place to file bugs for these modules.