|
Bugzilla – Full Text Bug Listing |
| Summary: | yast2-gtk: package selector truncate segfault | ||
|---|---|---|---|
| Product: | [openSUSE] openSUSE 11.0 | Reporter: | Joe Harmon <jharmon> |
| Component: | YaST2 | Assignee: | Forgotten User h13THG8RK1 <forgotten_h13THG8RK1> |
| Status: | RESOLVED FIXED | QA Contact: | Jiri Srain <jsrain> |
| Severity: | Critical | ||
| Priority: | P5 - None | CC: | forgotten_h13THG8RK1, michael.meeks |
| Version: | Final | ||
| Target Milestone: | --- | ||
| Hardware: | x86-64 | ||
| OS: | All | ||
| Whiteboard: | |||
| Found By: | --- | Services Priority: | |
| Business Priority: | Blocker: | --- | |
| Marketing QA Status: | --- | IT Deployment: | --- |
| Attachments: |
screenshot of segfault
yast files backtrace repos second backtrace third backtrace YGPackageSelector.cc |
||
|
Description
Joe Harmon
2008-08-20 15:53:52 UTC
Assignment to Ricardo Cruz <rpmcruz@alunos.dcc.fc.up.pt> was per Jiri. Created attachment 234501 [details]
screenshot of segfault
Created attachment 234515 [details]
yast files
Hi Joe. Would be great if you could run yast2 through gdb so we could get a nice backtrace. Please, run: gdb --args /usr/lib/YaST2/bin/y2base sw_single gtk run (you may have to press Return a couple of times) (try select packages to trigger the crash) backtrace Also, clarify whether the system is 32-bit or 64-bit, and attach a tarball of /etc/zypp/repos.d/ if you could. I am getting a lot of (no debugging symbols found).... what -devel packages do I need to have installed? Joe, just hit Return a couple of times there, while you see stuff like: (no debugging symbols found) (no debugging symbols found) (no debugging symbols found) (no debugging symbols found) ---Type <return> to continue, or q <return> to quit--- yast2-gtk is already compiled with the debug symbols; I guess that stuff is from the rest of yast, libraries or something. It doesn't interest us. Anyway, it would be great if you could just fill the Hardware (x86 or x86-64?) in the Product Information box... "gdb --args /usr/lib/YaST2/bin/y2base sw_single gtk" doesn't show the problem, only the add on product shows the issue. So I ran the following instead: "gdb --args /usr/lib/YaST2/bin/y2base add-on gtk" here is the output and this is on x86_64: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x40f26950 (LWP 4031)] 0x00007f8a4d7e55f8 in std::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string () from /usr/lib64/libstdc++.so.6 Dude, I want that backtrace! =) Check there my comment 4 again: 1. gdb 1.1. run -> 1.2. backtrace By the way, odd that you can only trigger it from the add-on tool. I guess it either adds more repos, or you need to click more packages there in sw_single (or use the filter) to get to the repository string triggering the crash... (In reply to comment #8 from Ricardo Cruz) > Dude, I want that backtrace! =) Check there my comment 4 again: > 1. gdb > 1.1. run > -> 1.2. backtrace lol... sorry man. I guess it has been a while since I did a backtrace... I thought it looked a little short. > By the way, odd that you can only trigger it from the add-on tool. I guess it > either adds more repos, or you need to click more packages there in sw_single > (or use the filter) to get to the repository string triggering the crash... Yeah, I found it strange as well. Created attachment 235862 [details]
backtrace
Well, it doesn't seem like -g is enabled there afterall... No line numbers or arguments. :( Since SVN truncate function is also different, in order to properly cope with utf-8 characters, it would be great if you could try it out:
1. Make sure you have installed:
g++, gtk2-devel, yast2-devtools, yast2-core-devel, libzypp-devel
(possibly configure may report more...)
2. Download it:
svn checkout http://svn.opensuse.org/svn/yast/trunk/gtk/ yast-gtk
3. Compile it:
cd yast-gtk
make -f Makefile.cvs
make && sudo make install
Alternatively, send me a tarball of /etc/zypp/repos.d/ as I asked previously, to see what repository names we are passing the function... I could find them among the yast logs, but that would be very tedious. ;)
Created attachment 236386 [details]
repos
Must have missed that one as well, sorry. Just a not on the repos. The one I am adding during the add on product is called ncl and I am adding it via the iso option. Just wanted to note that since it is not in this list. I assume that it is not in this list because it fails during the selecting of the package.
(In reply to comment #11 from Ricardo Cruz) > 1. Make sure you have installed: > g++, gtk2-devel, yast2-devtools, yast2-core-devel, libzypp-devel > (possibly configure may report more...) I see and am installing everything except g++. I don't see that package anywhere. Ups. It seems the g++ package is called "gcc-c++". Anyway, that likely has already been installed by the -devel packages... What you may also want to make sure is installed is "yast2-libyui-devel" and "yast2-ycp-ui-bindings-devel". Thanks for the trouble! Created attachment 236398 [details]
second backtrace
I was able to get the g++ and other dependencies figured out. I assume that you wanted me to run though the procedure again after doing all that and get another backtrace. Here it is.
Great! I will be checking that out tomorrow... Okay, caught the bugger. It seems that zypp doesn't have the repository you added in add-on in their repository API -- maybe those are just the stored ones, or maybe the repo gets added after the Package Selector UI is constructed. Anyway, we obviously weren't sanitizing things well. If you follow again the steps from comment 11, from the 2nd one, it should be fixed. What would be great now, to end this matter, is if you could just try a couple of things there, to see at what point is the seed of the mess planted. 1) try out the add-on tool with the Qt interface (/usr/lib/YaST2/bin/y2base add-on qt): select some package that crashed the GTK UI, and check the Versions tab for that package. Does it show the repository you added in that "1.0.0 from repo-X" list?) 2) is the repository you added listed in the GTK UI Repositories list? (if you select the "Groups" menu button, there is a "Repositories" entry there that will list the known repositories...) And if you select the new repository, does it filter the packages correctly? Nope still failed. Adding new backtrace. Created attachment 237264 [details]
third backtrace
Sure you're using the SVN version? In the backtrace the YGPackageSelector.cc line should be 1722, not 1721. If you look at src/YGPackageSelector.cc, you should have: 1720 string repo; 1721 if (version->repo) 1722 repo = YGUtils::truncate (version->repo->name, 1723 MAX (20, version->number.length() + version->arch.length() + 4), 0); I can't "emulate" the bug now... Created attachment 237650 [details] YGPackageSelector.cc I followed the instructions outlined in comment #11 as you suggested and it failed again. I have also attached the YGPackageSelector.cc and yes it does look to be correct Joe, I've googled for some repository to feed the addon tool with, so I can test your problem, but only howtos to create such repos seem to come up. Could you point me to the one you're using or any one at all. Otherwise, it seems there is a nice yast tool I can use to create one, and I'll try that one. It's best I replicate the crash here, so to not bother you anymore ;) and do some side testing. I can't give you this particular client yet because it is proprietary code that we have not yet approved for release, but you can use a 10.3 version that has been approved for release. You won't be able to install the packages but it fails before that point and it will allow you to reproduce the issue. Please do the following: (1) Go to www.novell.com/beta and under the Public beta section click on Novell Client for Linux 2.0 SP1 and download the ISO with the appropriate architecture. (2) Go into yast2, add on product and add the ISO as an add on product using the ISO option. (3) You will then get to the software screen. Now typically the software is automatically selected as part of the add on product. For some reason it is not happening by default in openSUSE 11.0 and I already have a bug in for that. So you will need to change the filter to patterns. (4) In the patterns section click on Novell Client on the left hand side and then select the novell-client package. That is were it will fail. Let me know if you run into any issues with this. Okay, so the earlier fix takes care of the crash here (maybe the previous installed gtk plugin is still being used there...). Anyway, the underlying issue -- that is, the add-on repository not being detected by the GTK UI -- is fixed now that I switched to some other Zypp API to query repositories, as used by the Qt UI, that seems like the proper one. That one has to fix things for you. Many thanks for bothering to follow this through. If possible, please do check if things work for you. By the way, every time I pressed Cancel, it seems the add-on tool wasn't cleaning up the repository, so I ended up with a plethora of those. Opened bug 424655. Thanks... I tried following comment #11 again to test the fix and I am getting the following error on the make and make install command YGDialog.cc:8:24: error: YDialogSpy.h: No such file or directory YGDialog.cc: In static member function ‘static gboolean YGWindow::key_pressed_cb(GtkWidget*, GdkEventKey*, YGWindow*)’: YGDialog.cc:245: error: ‘YDialogSpy’ has not been declared make[2]: *** [YGDialog.lo] Error 1 make[2]: Leaving directory `/home/jharmon/Desktop/yast-gtk/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/jharmon/Desktop/yast-gtk' make: *** [all] Error 2 It looks like it is looking for YDialogSpy.h file but that doesn't seem to come with openSUSE 11.0. Thoughts? The same branch is used for 11.0 and current development. Forgot to check for yast version when adding support for this new feature. Please try SVN again. Now I am getting the following: YGPushButton.lo YGPushButton.cc g++ -DHAVE_CONFIG_H -I. -I.. -I./include -I/usr/include/YaST2 -I/usr/include/YaST2/yui -pthread -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/freetype2 -I/usr/include/libpng12 -DY2LOG=\"ui-gtk\" -DTHEMEDIR=\"/usr/share/YaST2/theme/current\" -DLOCALEDIR=\"/usr/share/YaST2/locale\" -g -O2 -Wall -Wformat=2 -MT YGPushButton.lo -MD -MP -MF .deps/YGPushButton.Tpo -c YGPushButton.cc -fPIC -DPIC -o .libs/YGPushButton.o YGPushButton.cc:60: error: ‘YButtonRole’ has not been declared YGPushButton.cc: In member function ‘void YGPushButton::setStockIcon(const std::string&)’: YGPushButton.cc:33: error: ‘role’ was not declared in this scope YGPushButton.cc:34: error: ‘YOKButton’ was not declared in this scope YGPushButton.cc:37: error: ‘YApplyButton’ was not declared in this scope YGPushButton.cc:40: error: ‘YCancelButton’ was not declared in this scope YGPushButton.cc: In member function ‘virtual void YGPushButton::setRole(int)’: YGPushButton.cc:62: error: ‘setRole’ is not a member of ‘YPushButton’ YGPushButton.cc:63: error: ‘YCustomButton’ was not declared in this scope make[2]: *** [YGPushButton.lo] Error 1 make[2]: Leaving directory `/home/jharmon/Desktop/yast-gtk/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/jharmon/Desktop/yast-gtk' make: *** [all] Error 2 Okay, so there's that too. :/ Hopefully, any new functionality is detected properly now... Yep, seems to be working now. Thanks for all of your hard work on this. Any idea when this will go out as an update? Can we get a yast2-gtk update package for this crash on the add-on tool? Its already packaged afaict, unless there are fixes past when the changelog in svn says this bug is fixed. I meant a 11.0 patch... Clearly Joe thinks it's important, putting up with my queries all this time. ;) |