Bug 14927

Summary: rpmdragora: The search of a package doesn't have any result
Product: Mageia Reporter: Dimitrios Glentadakis <dglent>
Component: RPM PackagesAssignee: Angelo Naselli <anaselli>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Normal CC: marja11, matteo.pasotti
Version: Cauldron   
Target Milestone: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Source RPM: adminpanel-1.0.0-0.15.mga5.src.rpm CVE:
Status comment:
Attachments: Output of the mana pan command
Screenshot with the problem
.rpmdragora that works

Description Dimitrios Glentadakis 2015-01-02 13:19:46 CET
I type the name of a package but there is no any result
I have chosen any any package's name in filter

I attach the output of the terminal


Reproducible: 

Steps to Reproduce:
Comment 1 Dimitrios Glentadakis 2015-01-02 13:20:19 CET
Created attachment 5779 [details]
Output of the mana pan command
Angelo Naselli 2015-01-02 14:17:46 CET

CC: (none) => matteo.pasotti

Comment 2 Angelo Naselli 2015-01-02 14:22:22 CET
what is that does not start really?
mana pan?
or rpmdragora? (maybe into mpan)

Status: NEW => ASSIGNED

Comment 3 Dimitrios Glentadakis 2015-01-02 15:09:45 CET
It starts without problem, only the research doesn't work (it searchs but there is no any result)
Comment 4 Dimitrios Glentadakis 2015-01-02 15:11:58 CET
Created attachment 5780 [details]
Screenshot with the problem
Comment 5 Marja Van Waes 2015-01-02 15:29:51 CET

I cannot reproduce the problem, at least not yet.

However I noticed that (except for with --ncurses), I got a lot of "examining synthesis file [/var/lib/urpmi/*" lines every time I started rpmdragora directly or selected "Install and Remove Software" from the panel.

I can't find such lines in your attachment.

Do they appear for you when starting rpmdrake?

CC: (none) => marja11

Comment 6 Dimitrios Glentadakis 2015-01-02 15:36:54 CET
Probably it has to be this the reason as i don't have any line about "synthesis file ... " etc
Comment 7 Angelo Naselli 2015-01-02 15:40:22 CET
Dimitros, rpmdrake works instead, doesn't it?

Marja, i cannot avoid that, as far as i understood also rpmdrake does. But i open to get any improvements :D
Comment 8 Marja Van Waes 2015-01-02 15:45:56 CET
@ Angelo
Yes, rpmdrake does that, too, and here it helps to find where the problem is, so I think it is better to keep this feature (and maybe add it to --ncurses, too ;-) )
Comment 9 Angelo Naselli 2015-01-02 19:12:12 CET
Marja dialogs seems there. Which one should be missed?

Dimitros, her it works. Can you explain better what you did to arrive to that?
I suspect you don't have any media configured... but i could be wrong
Comment 10 Dimitrios Glentadakis 2015-01-03 05:40:24 CET
i have media configured, i use cli urpmi normaly

Here is the output when i try to reload the media
Use of uninitialized value $default_list_mode in hash element at
        /usr/bin/rpmdragora line 615 (#1)
Use of uninitialized value in hash element at /usr/bin/rpmdragora line 660 (#1)
<WRN> [qt-ui] YQGenericButton.cc:135 setIcon(): Can't load icon "/usr/share/icons/gnome/22x22/actions/gtk-clear.png"
Use of uninitialized value $mode in hash element at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/gui.pm line 1629 (#1)
Use of uninitialized value $mode in string eq at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/gui.pm line 1631 (#1)
Menu Reload the packages list chosen
Use of uninitialized value $e in string eq at
        /usr/lib/perl5/vendor_perl/5.20.1/MDK/Common/DataStructure.pm line 131 (#1)


I have a popup window and it says that i don't have any media active
Comment 11 Marja Van Waes 2015-01-03 11:11:46 CET
(In reply to Angelo Naselli from comment #7)
> Dimitros, rpmdrake works instead, doesn't it?
> 

@ Dimitrios

Can you please confirm that using rpmdrake to search works fine?
Comment 12 Dimitrios Glentadakis 2015-01-03 11:29:55 CET
I confirm that rpmdrake it works
Comment 13 Angelo Naselli 2015-01-03 11:40:16 CET
On comment #10 thanks for reporting that i will check what is wrong (at least for icons i cannot trust that the rpmdrake ones are installed). 
I have to investigate the $mode, but those warnings should not be related to your problem. You attached a snapshot that shows only the search png on the left panel.
I would have expected also all the rpm group categories. So you don't have somehow the media configured, at least rpmdragora can't find them, as probably confirmed by your last:
"I have a popup window and it says that i don't have any media active".

So it's important to understand either what you did to have this situation (installed from scratch, updated, etc.), I mean any steps, and if rpmdrake has the same behaviour. Otherwise i failed to port something from it. 
rpmdragora is not completed yet, but should work for most functionality.
Comment 14 Angelo Naselli 2015-01-03 11:44:55 CET
For comment #12 fine -or maybe not :D-, so the steps you made are important. Because it works here and that is probably because i have something you don't have... or better the contrary :)
Comment 15 Dimitrios Glentadakis 2015-01-03 12:02:36 CET
I reinstalled the package:
[root@localhost ~]# urpmi --replacepkgs adminpanel-qt


    ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/core/release/adminpanel-qt-1.0.0-0.15.mga5.x86_64.rpm
installing adminpanel-qt-1.0.0-0.15.mga5.x86_64.rpm from /var/cache/urpmi/rpms                  
Preparing...                     ##############################################################
      1/1: adminpanel-qt         ##############################################################
[root@localhost ~]# 

i choose update the media: I have a window that i don't have any media
I choose media manager
I choose File > update
I check all media > Update
It waits 2 secondes and it goes to 100%


Maybe here you can see something :

Use of uninitialized value $default_list_mode in hash element at
        /usr/bin/rpmdragora line 615 (#1)
Use of uninitialized value in hash element at /usr/bin/rpmdragora line 660 (#1)
<WRN> [qt-ui] YQGenericButton.cc:135 setIcon(): Can't load icon "/usr/share/icons/gnome/22x22/actions/gtk-clear.png"
Use of uninitialized value $mode in hash element at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/gui.pm line 1629 (#1)
Use of uninitialized value $mode in string eq at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/gui.pm line 1631 (#1)
Menu Options chosen
Menu &Media Manager chosen
getting exclusive lock on urpmi
wrote config file [/etc/urpmi/urpmi.cfg]
unlocking urpmi database
Menu Reload the packages list chosen
Use of uninitialized value $e in string eq at
        /usr/lib/perl5/vendor_perl/5.20.1/MDK/Common/DataStructure.pm line 131 (#1)
Menu Update media chosen
Menu &Media Manager chosen
getting exclusive lock on urpmi
<_M_> [mga-qt-ui] YMGA_QCBTable.cc:74 YMGA_QCBTable():  Slection mode 2
<WRN> [ui-shortcuts] YShortcutManager.cc:85 checkShortcuts(): Not enough widgets with valid shortcut characters - no check
not using metalink since requested downloader does not handle it
retrieved ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/core/release media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/Core Release/MD5SUM
medium "Core Release" is up-to-date
retrieved ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/core/updates media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/Core Updates/MD5SUM
medium "Core Updates" is up-to-date
retrieved ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/nonfree/release media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/Nonfree Release/MD5SUM
medium "Nonfree Release" is up-to-date
retrieved ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/nonfree/updates media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/Nonfree Updates/MD5SUM
medium "Nonfree Updates" is up-to-date
retrieved ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/tainted/release media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/Tainted Release/MD5SUM
medium "Tainted Release" is up-to-date
retrieved ftp://ftp-stud.hs-esslingen.de/pub/Mirrors/Mageia/distrib/cauldron/x86_64/media/tainted/updates media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/Tainted Updates/MD5SUM
medium "Tainted Updates" is up-to-date
retrieved http://www.mageia-gr.org/rpm/5/x86_64 media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/mgr-64/MD5SUM
medium "mgr-64" is up-to-date
retrieved http://www.mageia-gr.org/rpm/5/noarch media_info/MD5SUM
comparing /var/cache/urpmi/partial/MD5SUM and /var/lib/urpmi/mgr-noarch/MD5SUM
medium "mgr-noarch" is up-to-date
Use of uninitialized value $updates_result{"1"} in numeric eq (==) at
        /usr/lib/perl5/vendor_perl/5.20.1/urpm/media.pm line 2100 (#1)
Use of uninitialized value $updates_result{"error"} in numeric eq (==) at
        /usr/lib/perl5/vendor_perl/5.20.1/urpm/media.pm line 2103 (#1)
<_M_> [qt-ui] YQMainWinDock.cc:303 closeEvent(): Caught window manager close event - returning with YCancelEvent
wrote config file [/etc/urpmi/urpmi.cfg]
unlocking urpmi database
<_M_> [qt-ui] YQMainWinDock.cc:303 closeEvent(): Caught window manager close event - returning with YCancelEvent
<_M_> [ui] YUILoader.cc:104 deleteUI(): Shutting down UI
<_M_> [ew] YExternalWidgets.cc:116 ~YExternalWidgetsTerminator(): Shutting down mga External Widgets
<_M_> [ew] YMGAWidgetExtensionFactory.cc:49 ~YMGAWidgetFactory(): Factory removed
<_M_> [qt-ui] YQMainWinDock.cc:303 closeEvent(): Caught window manager close event - returning with YCancelEvent
<_M_> [ui] YUILoader.cc:104 deleteUI(): Shutting down UI
Comment 16 Angelo Naselli 2015-01-03 12:21:58 CET
are you running rpmdragora from root user or by using polkit to get the rights?
Comment 17 Angelo Naselli 2015-01-03 12:28:27 CET
and do you have /root/.rpmdragora after you run it once? and if what is its content?
I'm confused here it works and i got only the icon warning (that is true i have to provide icons instead of taking the drakx ones)
Comment 18 Angelo Naselli 2015-01-03 12:44:50 CET
and neither to the gnome one :D
<WRN> [qt-ui] YQGenericButton.cc:135 setIcon(): Can't load icon "/usr/share/icons/gnome/22x22/actions/gtk-clear.png"
Comment 19 Dimitrios Glentadakis 2015-01-03 13:31:31 CET
(In reply to Angelo Naselli from comment #17)
> and do you have /root/.rpmdragora after you run it once? and if what is its
> content?
> I'm confused here it works and i got only the icon warning (that is true i
> have to provide icons instead of taking the drakx ones)

Yes, :

filter all
tree_flat 0
rpmdrake_height 769
NVR_searches 0
no-confirmation 1
clean_cache 0
tree_mode all
mode by_group
mandrakeupdate_wanted_categories 
rpmdrake_width 1248
mandrivaupdate_width 1126
ignore_debug_media 0
use_regexp 0
compute_updates 1
offered_to_add_sources 1
dont_show_selections 
auto_select 1
changelog_first_config 0
max_info_in_descr 
mandrivaupdate_height 652
Comment 20 Dimitrios Glentadakis 2015-01-03 13:32:57 CET
(In reply to Angelo Naselli from comment #16)
> are you running rpmdragora from root user or by using polkit to get the
> rights?

before from user via policykit, now i tried via root, the same::

Use of uninitialized value $default_list_mode in hash element at
        /usr/bin/rpmdragora line 615 (#1)
Use of uninitialized value in hash element at /usr/bin/rpmdragora line 660 (#1)
<WRN> [qt-ui] YQGenericButton.cc:135 setIcon(): Can't load icon "/usr/share/icons/gnome/22x22/actions/gtk-clear.png"
Use of uninitialized value $mode in hash element at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/gui.pm line 1629 (#1)
Use of uninitialized value $mode in string eq at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/gui.pm line 1631 (#1)
<WRN> [qt-ui] YQDialog.cc:559 activateDefaultButton(): No default button in this dialog - ignoring [Return]

Calling POSIX::isdigit() is deprecated at
        /usr/lib/perl5/vendor_perl/5.20.1/AdminPanel/Rpmdragora/icon.pm line 218 (#2)
    (D deprecated) You called a function whose use is deprecated.  See
    the function's name in POSIX for details.
    
TODO ==================> ADD NODES - add packages (0) 
 at /usr/bin/rpmdragora line 353.
Use of uninitialized value $default_list_mode in string eq at
        /usr/bin/rpmdragora line 354 (#1)
Menu Update media chosen
<_M_> [qt-ui] YQMainWinDock.cc:303 closeEvent(): Caught window manager close event - returning with YCancelEvent
<_M_> [ui] YUILoader.cc:104 deleteUI(): Shutting down UI
<_M_> [ew] YExternalWidgets.cc:116 ~YExternalWidgetsTerminator(): Shutting down mga External Widgets
<_M_> [ew] YMGAWidgetExtensionFactory.cc:49 ~YMGAWidgetFactory(): Factory removed
<_M_> [qt-ui] YQMainWinDock.cc:303 closeEvent(): Caught window manager close event - returning with YCancelEvent
<_M_> [ui] YUILoader.cc:104 deleteUI(): Shutting down UI
Comment 21 Angelo Naselli 2015-01-03 16:08:38 CET
If you run rpmdragora as normal user do you have the info dialog saying:
"You are launching this program as a normal user.
You will not be able to perform modifications on the system,
but you may still browse the existing database." ?

To run rpmdragora as normal user just type into console as user
rpmdragora and press enter.
Comment 22 Dimitrios Glentadakis 2015-01-04 08:55:56 CET
Ok now it works (i renamed the .rpmdragora)

[root@localhost ~]# diff -u .rpmdragora11 .rpmdragora
--- .rpmdragora11       2015-01-03 13:30:22.817315969 +0100
+++ .rpmdragora 2015-01-04 08:53:33.480419580 +0100
@@ -1,20 +1,20 @@
-ignore_debug_media 0
-use_regexp 0
-filter 
-dont_show_selections 0
-mandrivaupdate_height 0
-mandrakeupdate_wanted_categories 
 offered_to_add_sources 0
-clean_cache 0
-compute_updates 1
-no-confirmation 0
-rpmdragora_width 0
-mode by_group
 tree_flat 0
 mandrivaupdate_width 0
+rpmdragora_width 0
+max_info_in_descr 
 rpmdragora_height 0
-tree_mode 
+dont_show_selections 0
+no-confirmation 0
+mode by_group
+filter all
+changelog_first_config 0
 auto_select 0
+compute_updates 1
+clean_cache 0
 NVR_searches 0
-changelog_first_config 0
-max_info_in_descr 
+use_regexp 0
+tree_mode gui_pkgs
+mandrakeupdate_wanted_categories security
+mandrivaupdate_height 0
+ignore_debug_media 0
[root@localhost ~]# 


The enter key should launch the research ?
Comment 23 Dimitrios Glentadakis 2015-01-04 08:59:40 CET
Created attachment 5783 [details]
.rpmdragora that works
Marja Van Waes 2015-01-04 09:20:31 CET

Attachment 5783 mime type: application/octet-stream => text/plain

Comment 24 Dimitrios Glentadakis 2015-01-04 09:33:42 CET
I can reproduce it
the problem is the parameter tree_mode
some tiles is set without any value

Doesn't work "tree_mode"
Works "tree_mode all"
Comment 25 Dimitrios Glentadakis 2015-01-04 09:34:30 CET
* some times is set without any value
Comment 26 Dimitrios Glentadakis 2015-01-04 09:42:52 CET
This happens only when launch rpmdragora from mana pan and not when run rpmdragora directly
Comment 27 Marja Van Waes 2015-01-04 09:48:17 CET
(In reply to Dimitrios Glentadakis from comment #23)
> Created attachment 5783 [details]
> .rpmdragora that works

Going by what you say later, this one can't work, it has no value for "tree mode"
Comment 28 Marja Van Waes 2015-01-04 09:49:32 CET
(In reply to Dimitrios Glentadakis from comment #26)
> This happens only when launch rpmdragora from mana pan and not when run
> rpmdragora directly

always when launching it from mana pan, or only sometimes when launching it from mana pan?
Comment 29 Marja Van Waes 2015-01-04 09:53:27 CET
(In reply to Dimitrios Glentadakis from comment #22)
> Ok now it works (i renamed the .rpmdragora)
> 
> [root@localhost ~]# diff -u .rpmdragora11 .rpmdragora
> --- .rpmdragora11       2015-01-03 13:30:22.817315969 +0100
> +++ .rpmdragora 2015-01-04 08:53:33.480419580 +0100
> @@ -1,20 +1,20 @@


The differences I see, if I ignore the order (which I don't think matters) are:

-filter 
+filter all
-mandrakeupdate_wanted_categories 
+mandrakeupdate_wanted_categories security
-tree_mode 
+tree_mode gui_pkgs
Comment 30 Dimitrios Glentadakis 2015-01-04 10:00:06 CET
I can reproduce it at any time when i launch rpmdragor from mana pan only
Then , if you change the filter for the packages, it writes 'tree-mode' without value.
Comment 31 Marja Van Waes 2015-01-04 10:06:50 CET
(In reply to Dimitrios Glentadakis from comment #30)
> I can reproduce it at any time when i launch rpmdragor from mana pan only
> Then , if you change the filter for the packages, it writes 'tree-mode'
> without value.

if that didn't already happen when starting rpmdragora from mana pan, then it could be caused by the bug and not be the bug itself :-/

Do you see "examining synthesis file [/var/lib/urpmi/*" lines when starting rpmdragora from mana pan?
Comment 32 Marja Van Waes 2015-01-04 10:12:41 CET
btw, for me all those syntesis files in /var/lib/urpmi/ have
drwxr-xr-x   2 root root
Comment 33 Dimitrios Glentadakis 2015-01-04 10:14:41 CET
Marja try to:

1. open rpmdragora from mana pan and change the package's filter.
2. Close the window
3. Reopen rpmdragora (through the control panel always)
4. You have no packages in the tree at the left column, and any search results to an empty list
5. open rpmdragora directly from the terminal
6. Change the packages filter
7. close the window
8. relanche rpmdragora from the terminal
9. You have the packages available
Comment 34 Marja Van Waes 2015-01-04 10:23:17 CET
(In reply to Marja van Waes from comment #32)
> btw, for me all those syntesis files in /var/lib/urpmi/ have
> drwxr-xr-x   2 root root

s/files/directories/

(In reply to Dimitrios Glentadakis from comment #33)
> Marja try to:
> 
> 1. open rpmdragora from mana pan and change the package's filter.

what is "package's filter" for you

Maybe i picked something else than you meant?
Comment 35 Dimitrios Glentadakis 2015-01-04 10:30:43 CET
package filter i mean if it is a meta-pqckage, applicqtion gui, etc the first filter at left of the filter installed / uninstalled packages
Comment 36 Marja Van Waes 2015-01-04 10:38:24 CET
(In reply to Dimitrios Glentadakis from comment #35)
> package filter i mean if it is a meta-pqckage, applicqtion gui, etc the
> first filter at left of the filter installed / uninstalled packages

OK, then I had correctly understood. I've tried several times, switching back and forth between all packages and GUI packages only, but it doesn't make a difference, when I close rpmdragora without closing mana pan and then start it from mana pan again, I can still search fine.
(and I keep always getting those "examining synthesis file" lines)

Sorry, I can't reproduce and can't spend more time trying to reproduce.

I'm glad you can workaround it by starting rpmdragora directly
Comment 37 Angelo Naselli 2015-01-04 13:38:18 CET
I seem to recall a bug related to rpmdrake for that. Workaround was to remove the configuration file and start ito again. I will check the read and write configuration file functionality and see if I can enforce the error chacking for the retrieved values
Comment 38 Dimitrios Glentadakis 2015-01-04 13:58:28 CET
it is strange also that even if i delete the configuration  file , i can reproduce it again by repeating the same steps.

i understand that the rpmdragora when closing it doesn't write rhe righr configuration  value. But when ir is launched directly it does.
Comment 39 Angelo Naselli 2015-01-04 20:50:38 CET
Dimitrios i can't reproduce it, but with the configuration you provide at comment #23 i can see the effect. And that is enough for me, I know that for some reasons rpmdragora wrongly saves the configuration, and I'm quite sure that happens somehow and sometime also in rpmdrake.
I'm fixing the read configuration operation to leave the default value if keys have empty values (there is only one case with empty values, but it's also as default atm) in future we could change the configuration file at all maybe if my change has other wrong side effects :)

Stay tuned to test new incoming package, and thanks for your report.
Angelo Naselli 2015-01-04 23:56:01 CET

Summary: Adminpanel-qt: The search of a package doesn't have any result => rpmdragora: The search of a package doesn't have any result

Comment 40 Angelo Naselli 2015-01-05 00:13:39 CET
new adminpanel is building. I could not avoid the wrong writing since i was not able to reproduce the cause of the problem, but at least now you should not have a wrong reading.
Please reopen this bug (or open a new one) if you think it is not fixed.

Status: ASSIGNED => RESOLVED
Resolution: (none) => FIXED

Comment 41 Dimitrios Glentadakis 2015-01-05 06:08:57 CET
I can reproduce it only in Greek language finally
Also the filters are not applied during my searches, i see all packages even if i have chosen only with gui, and the same if i choose only the installed packages, i see all packages, in Greek localisation only.
Comment 42 Dimitrios Glentadakis 2015-01-05 06:18:13 CET
With the new version i don't have the bug because the null value is not written and when i restart i have the default value.

Status: RESOLVED => REOPENED
Resolution: FIXED => (none)

Dimitrios Glentadakis 2015-01-05 06:19:36 CET

Summary: rpmdragora: The search of a package doesn't have any result => rpmdragora: The packages' filters don't applyied in Greek localisation

Comment 43 Angelo Naselli 2015-01-05 10:42:09 CET
Dimitrios please open a new bug for filters (that i need to check if they are really implemented atm in rpmdragora though) and localization is just taken from rpmdrake atm, so not all is translated. That to avoid to overload translator at this stage.

Summary: rpmdragora: The packages' filters don't applyied in Greek localisation => rpmdragora: The search of a package doesn't have any result

Comment 44 Angelo Naselli 2015-01-05 10:43:42 CET
last report at comment #42 shows that this bug is fixed, comment #41 needs a new bug report with further studies

Status: REOPENED => RESOLVED
Resolution: (none) => FIXED