!21 fix gtkdoc-rebase NoneType object has no attribute group error

From: @wang--ge
Reviewed-by: @orange-snn
Signed-off-by: @orange-snn
This commit is contained in:
openeuler-ci-bot 2021-07-26 11:02:27 +00:00 committed by Gitee
commit 1f4507c2ff
2 changed files with 33 additions and 2 deletions

View File

@ -0,0 +1,27 @@
From 1caecce7002efded6cc3cc95e17372a98189b6f1 Mon Sep 17 00:00:00 2001
From: wang--ge <wang__ge@126.com>
Date: Mon, 26 Jul 2021 16:21:42 +0800
Subject: [PATCH] fix gtkdoc-rebase NoneType object has no attribute group
error
---
gtkdoc/rebase.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/gtkdoc/rebase.py b/gtkdoc/rebase.py
index 31a9b4f..60a8ebf 100755
--- a/gtkdoc/rebase.py
+++ b/gtkdoc/rebase.py
@@ -228,7 +228,8 @@ def RebaseLink(href, options):
package = match.group(1)
elif options.aggressive:
match = re.search(r'''([^/]+)/$''', href)
- package = match.group(1)
+ if not match is None:
+ package = match.group(1)
if package:
if options.online and package in OnlineMap:
--
2.27.0

View File

@ -3,13 +3,14 @@
Name: gtk-doc
Version: 1.33.2
Release: 2
Release: 3
Summary: Generate API documentation from comments that can be added to C code
License: GPLv2+ and GFDL
URL: https://www.gtk.org/gtk-doc/
Source0: https://download.gnome.org/sources/gtk-doc/1.33/%{name}-%{version}.tar.xz
Patch0: fix-fixxref-not-found-file.patch
Patch1: fix-mkdb-not-found-file.patch
Patch2: fix-gtkdoc-rebase-NoneType-object-has-no-attribute-group.patch
BuildRequires: python3-devel docbook-utils libxslt gettext
BuildRequires: itstool yelp-tools docbook-style-xsl gcc gdb
@ -18,7 +19,7 @@ BuildRequires: python3-pygments
BuildRequires: python3-parameterized
BuildRequires: python3-anytree
BuildRequires: python3-lxml
Requires: docbook-style-xsl docbook-utils libxslt
Requires: docbook-style-xsl docbook-utils libxslt glib2-devel
Requires: python3-pygments python3-parameterized python3-anytree python3-lxml
@ -54,6 +55,9 @@ export PYTHON=%{__python3}
%{_datadir}/help/*/%{name}-manual/
%changelog
* Non Jul 26 2021 Ge Wang <wangge20@huawei.com> - 1.33.2-3
- fix gtkdoc-rebase NoneType object has no attribute 'group'
* Sun Jul 25 2021 liyanan <liyanan32@huawei.com> - 1.33.2-2
- fix not found file