diff --git a/.gitignore b/.gitignore index a216e0d..381b5e4 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,4 @@ /gnome-abrt-0.2.11.tar.gz /gnome-abrt-0.2.12.tar.gz /gnome-abrt-0.3.0.tar.gz +/gnome-abrt-0.3.1.tar.gz diff --git a/0001-Do-not-crash-on-None-in-signal-handler.patch b/0001-Do-not-crash-on-None-in-signal-handler.patch new file mode 100644 index 0000000..e199d22 --- /dev/null +++ b/0001-Do-not-crash-on-None-in-signal-handler.patch @@ -0,0 +1,35 @@ +From 4eefc61078eb21a7446d9030b14bd26abd10c72a Mon Sep 17 00:00:00 2001 +From: Jakub Filak +Date: Fri, 13 Sep 2013 08:56:21 +0200 +Subject: [GNOME-ABRT PATCH 1/3] Do not crash on None in signal handler + +Closes rhbz#1005472 + +Signed-off-by: Jakub Filak +--- + src/gnome_abrt/views.py | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/src/gnome_abrt/views.py b/src/gnome_abrt/views.py +index 1d7ddb9..dfea616 100644 +--- a/src/gnome_abrt/views.py ++++ b/src/gnome_abrt/views.py +@@ -497,6 +497,15 @@ class OopsWindow(Gtk.ApplicationWindow): + + if storage_problems: + model = self._builder.tv_problems.get_model() ++ ++ # For some strange reason, get_model() sometimes returns None when ++ # this function is called from a signal handler but the signal ++ # handler is synchronously called from GMainLoop so there is no ++ # place for race conditions. If the described situation arises, ++ # base model will be used. ++ if model is None: ++ model = self._builder.ls_problems ++ + pit = None + if old_selection: + pit = self._find_problem_iter(old_selection[0], model) +-- +1.8.3.1 + diff --git a/0002-Fix-issues-found-by-new-pylint.patch b/0002-Fix-issues-found-by-new-pylint.patch new file mode 100644 index 0000000..76a3556 --- /dev/null +++ b/0002-Fix-issues-found-by-new-pylint.patch @@ -0,0 +1,189 @@ +From 562e606040b0e281b675425ec81ecd004f14040c Mon Sep 17 00:00:00 2001 +From: Jakub Filak +Date: Fri, 13 Sep 2013 10:43:25 +0200 +Subject: [GNOME-ABRT PATCH 2/3] Fix issues found by new pylint + +Closes #30 + +Signed-off-by: Jakub Filak +--- + pylintrc | 6 +++--- + src/gnome_abrt/application.py | 2 +- + src/gnome_abrt/config.py | 3 ++- + src/gnome_abrt/dbus_problems.py | 3 ++- + src/gnome_abrt/directory_problems.py | 6 +++--- + src/gnome_abrt/problems.py | 6 +++--- + src/gnome_abrt/views.py | 6 +++--- + 7 files changed, 17 insertions(+), 15 deletions(-) + +diff --git a/pylintrc b/pylintrc +index fdb32d3..ee3d219 100644 +--- a/pylintrc ++++ b/pylintrc +@@ -12,7 +12,7 @@ profile=no + + # Add files or directories to the blacklist. They should be base names, not + # paths. +-ignore=.git,gnome_abrt_glade.py ++ignore=.git,gnome_abrt_glade.py,_wrappers.so + + # Pickle collected data for later comparisons. + persistent=yes +@@ -33,7 +33,7 @@ load-plugins= + # can either give multiple identifier separated by comma (,) or put this option + # multiple time (only on the command line, not in the configuration file where + # it should appear only once). +-disable=C0111,W0212,R0201,R0903,R0904,I0011,W0603,W0622,I0001 ++disable=C0111,W0212,R0201,R0903,R0904,I0011,W0603,W0622,I0001,R0912 + + + [REPORTS] +@@ -41,7 +41,7 @@ disable=C0111,W0212,R0201,R0903,R0904,I0011,W0603,W0622,I0001 + # Set the output format. Available formats are text, parseable, colorized, msvs + # (visual studio) and html. You can also give a reporter class, eg + # mypackage.mymodule.MyReporterClass. +-output-format=parseable ++msg-template={path}:{line}: [{msg_id}({symbol}), {obj}] {msg} % (self.name, self.line_format)) + + # Include message's id in output + include-ids=yes +diff --git a/src/gnome_abrt/application.py b/src/gnome_abrt/application.py +index e4e24d9..140042c 100644 +--- a/src/gnome_abrt/application.py ++++ b/src/gnome_abrt/application.py +@@ -81,7 +81,7 @@ def compare_cmdline(cmdline, desktop_entry): + + # try to handle interpreters like python + if not ret: +- cmdargs = filter(lambda x: x, cmdline.split(" ")) ++ cmdargs = [x for x in cmdline.split(" ") if x] + if len(cmdargs) > 1: + ret = compare_executable(cmdargs[1], desktop_entry) + +diff --git a/src/gnome_abrt/config.py b/src/gnome_abrt/config.py +index 0506b78..94aea46 100644 +--- a/src/gnome_abrt/config.py ++++ b/src/gnome_abrt/config.py +@@ -46,7 +46,8 @@ class Configuration(object): + oldvalue = opt.value + if oldvalue != value: + opt.value = value +- map(lambda o: o.option_updated(self, option), opt.observers) ++ for observer in opt.observers: ++ observer.option_updated(self, option) + + def __delitem__(self, option): + pass +diff --git a/src/gnome_abrt/dbus_problems.py b/src/gnome_abrt/dbus_problems.py +index 1c964d5..342fa18 100644 +--- a/src/gnome_abrt/dbus_problems.py ++++ b/src/gnome_abrt/dbus_problems.py +@@ -200,7 +200,7 @@ class StandardProblems(DBusProblemSource.Driver): + def __init__(self, source): + super(StandardProblems, self).__init__(source) + +- class ConfigObserver(): ++ class ConfigObserver(object): + def __init__(self, source): + self._source = source + +@@ -212,6 +212,7 @@ class StandardProblems(DBusProblemSource.Driver): + conf = config.get_configuration() + conf.set_watch("all_problems", ConfigObserver(self._source)) + ++ #pylint: disable=W0142 + @property + def get_problems_method(self): + conf = config.get_configuration() +diff --git a/src/gnome_abrt/directory_problems.py b/src/gnome_abrt/directory_problems.py +index 29a7ed0..1c58b34 100644 +--- a/src/gnome_abrt/directory_problems.py ++++ b/src/gnome_abrt/directory_problems.py +@@ -150,7 +150,7 @@ class INOTIFYSourceHandler(ProcessEvent): + .format(ex)) + + +-class INOTIFYWatcher: ++class INOTIFYWatcher(object): + + def __init__(self, source, directory, context): + # context is the instance variable because +@@ -219,7 +219,7 @@ _("You have probably reached inotify's limit on the number of watches in '{0}'." + "about changes in problem data happening outside of this application. This " + "event do not affect any other functionality.").format(self._directory)) + +-class NotInitializedDirectorySource(): ++class NotInitializedDirectorySource(object): + + def __init__(self, parent): + self._parent = parent +@@ -245,7 +245,7 @@ class NotInitializedDirectorySource(): + return True + + +-class InitializedDirectoryProblemSource(): ++class InitializedDirectoryProblemSource(object): + + def __init__(self, parent, directory, context=None): + self._parent = parent +diff --git a/src/gnome_abrt/problems.py b/src/gnome_abrt/problems.py +index 6e00c40..517cc5a 100644 +--- a/src/gnome_abrt/problems.py ++++ b/src/gnome_abrt/problems.py +@@ -63,11 +63,11 @@ class ProblemSource(object): + def refresh(self): + pass + +-class Problem: ++class Problem(object): + INITIAL_ELEMENTS = ['component', 'executable', 'cmdline', 'count', 'type', + 'last_occurrence', 'time', 'reason'] + +- class Submission: ++ class Submission(object): + URL = "URL" + MSG = "MSG" + BTHASH = "BTHASH" +@@ -288,7 +288,7 @@ class MultipleSources(ProblemSource): + + self.sources = sources + +- class SourceObserver: ++ class SourceObserver(object): + def __init__(self, parent): + self.parent = parent + +diff --git a/src/gnome_abrt/views.py b/src/gnome_abrt/views.py +index dfea616..d85affc 100644 +--- a/src/gnome_abrt/views.py ++++ b/src/gnome_abrt/views.py +@@ -59,7 +59,7 @@ def problems_filter(model, itrtr, data): + return match_pattern(pattern, model[itrtr][2]) + + +-class ProblemsFilter: ++class ProblemsFilter(object): + + def __init__(self, window, view): + self.current_pattern = "" +@@ -188,7 +188,7 @@ class OopsWindow(Gtk.ApplicationWindow): + return obj + + +- class SourceObserver: ++ class SourceObserver(object): + def __init__(self, wnd): + self.wnd = wnd + self._enabled = True +@@ -219,7 +219,7 @@ class OopsWindow(Gtk.ApplicationWindow): + self.wnd._disable_source(ex.source, ex.temporary) + + +- class OptionsObserver: ++ class OptionsObserver(object): + def __init__(self, wnd): + self.wnd = wnd + +-- +1.8.3.1 + diff --git a/0003-Do-not-change-old-selection-upon-reloading.patch b/0003-Do-not-change-old-selection-upon-reloading.patch new file mode 100644 index 0000000..330d5ff --- /dev/null +++ b/0003-Do-not-change-old-selection-upon-reloading.patch @@ -0,0 +1,27 @@ +From e1af12a4163200e119263fb16eb2ab2da0e438a7 Mon Sep 17 00:00:00 2001 +From: Jakub Filak +Date: Fri, 13 Sep 2013 11:02:32 +0200 +Subject: [GNOME-ABRT PATCH 3/3] Do not change old selection upon reloading + +Closes #29 + +Signed-off-by: Jakub Filak +--- + src/gnome_abrt/views.py | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/src/gnome_abrt/views.py b/src/gnome_abrt/views.py +index d85affc..2abacc3 100644 +--- a/src/gnome_abrt/views.py ++++ b/src/gnome_abrt/views.py +@@ -485,7 +485,6 @@ class OopsWindow(Gtk.ApplicationWindow): + old_selection = self._get_selected(self._builder.tvs_problems) + + self._reloading = True +- old_selection = None + try: + self._builder.ls_problems.clear() + +-- +1.8.3.1 + diff --git a/gnome-abrt-0.2.12-disable-downloading-of-html-titles.patch b/gnome-abrt-0.2.12-disable-downloading-of-html-titles.patch deleted file mode 100644 index 56ef252..0000000 --- a/gnome-abrt-0.2.12-disable-downloading-of-html-titles.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff -ruN gnome-abrt-0.2.12/src/gnome-abrt gnome-abrt-0.2.12.new/src/gnome-abrt ---- gnome-abrt-0.2.12/src/gnome-abrt 2013-05-03 11:10:14.000000000 +0200 -+++ gnome-abrt-0.2.12.new/src/gnome-abrt 2013-05-06 14:07:36.042188707 +0200 -@@ -177,7 +177,9 @@ - self.all_sources = None - self._url_pool = GetURLTitleSourcePool(GNOME_ABRT_URL_POOL_CAPACITY) - self._url_cache = GetURLTitleSourceCache(self._url_pool) -- gnome_abrt.url.set_async_worker(self._url_cache.get_url_title_async) -+ #gnome_abrt.url.set_async_worker(self._url_cache.get_url_title_async) -+ # Disable because of https://bugzilla.redhat.com/show_bug.cgi?id=959811 -+ gnome_abrt.url.set_async_worker(lambda *args: None) - - #pylint: disable=W0613 - def _parse_command_line(self, sender, gcmdargs): diff --git a/gnome-abrt.spec b/gnome-abrt.spec index 134b448..7410d77 100644 --- a/gnome-abrt.spec +++ b/gnome-abrt.spec @@ -5,8 +5,8 @@ # ! no binaries in $PATH ... caused by gnome-abrt python script in /usr/bin Name: gnome-abrt -Version: 0.3.0 -Release: 3%{?dist} +Version: 0.3.1 +Release: 1%{?dist} Summary: A utility for viewing problems that have occurred with the system Group: User Interface/Desktops @@ -14,8 +14,10 @@ License: GPLv2+ URL: https://fedorahosted.org/abrt/ Source0: https://fedorahosted.org/released/abrt/%{name}-%{version}.tar.gz -# remove if https://bugzilla.redhat.com/show_bug.cgi?id=959811 is fixed -Patch1: gnome-abrt-0.2.12-disable-downloading-of-html-titles.patch +# Remove it with gnome-abrt > 0.3.1 +Patch1: 0001-Do-not-crash-on-None-in-signal-handler.patch +Patch2: 0002-Fix-issues-found-by-new-pylint.patch +Patch3: 0003-Do-not-change-old-selection-upon-reloading.patch BuildRequires: intltool BuildRequires: gettext @@ -26,6 +28,7 @@ BuildRequires: asciidoc BuildRequires: xmlto BuildRequires: pygobject3-devel BuildRequires: libreport-gtk-devel >= 2.0.20 +BuildRequires: abrt-gui-devel >= 2.1.7 BuildRequires: gtk3-devel %if 0%{?fedora} BuildRequires: pylint @@ -49,6 +52,8 @@ provides them with convenient way for managing these problems. %prep %setup -q %patch1 -p1 +%patch2 -p1 +%patch3 -p1 %build @@ -96,12 +101,25 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %{_datadir}/%{name} %{_bindir}/%{name} %{_datadir}/applications/* +%{_datadir}/appdata/* %{_mandir}/man1/%{name}.1* %{_datadir}/icons/hicolor/*/apps/* %{_datadir}/icons/hicolor/*/status/* %changelog +* Thu Sep 12 2013 Jakub Filak 0.3.1-1 +- Improve user experience +- Make About dialog transient for the main window +- Add AppData file +- Ship the 256x256 icon in the right place +- Recover from fork errors +- Add ABRT configure application menu +- Use absolute path in python shebang +- Recover from invalid time stamp values +- Use wrapped text for the bug report link +- Resolves: #1004276 + * Fri Jul 26 2013 Jakub Filak 0.3.0-1 - Do not include url files twice - Get rid of Stock Items usage diff --git a/sources b/sources index acda347..6f31dbe 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -9c9e44a255b1b63f3adc31c834f30b2e gnome-abrt-0.3.0.tar.gz +da53340545295eed5066979c72620bee gnome-abrt-0.3.1.tar.gz