Bug 759467 - RFE: Allow multiple groups in re
RFE: Allow multiple groups in re
Status: CLOSED UPSTREAM
Product: Fedora
Classification: Fedora
Component: cnucnu (Show other bugs)
rawhide
x86_64 Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Susi Lehtola
Fedora Extras Quality Assurance
abrt_hash:3123c228
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-12-02 08:03 EST by Jaroslav Škarvada
Modified: 2015-01-31 09:12 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-01-31 09:12:58 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
File: backtrace (1.07 KB, text/plain)
2011-12-02 08:03 EST, Jaroslav Škarvada
no flags Details
Proposed patch (786 bytes, patch)
2011-12-02 09:40 EST, Jaroslav Škarvada
no flags Details | Diff
Improved patch (787 bytes, patch)
2011-12-02 11:00 EST, Jaroslav Škarvada
no flags Details | Diff

  None (edit)
Description Jaroslav Škarvada 2011-12-02 08:03:43 EST
abrt version: 1.1.18
architecture: x86_64
comment: It shouldn't abrt, but write some error and cleanly exit.
component: cnucnu
executable: /usr/bin/cnucnu
kernel: 2.6.35.14-106.fc14.x86_64
package: cnucnu-0-0.7.20110308git2033ec78.fc14
reason: helper.py:175:split_rc:TypeError: expected string or buffer
release: Fedora release 14 (Laughlin)
time: 1322830740
uid: 500

backtrace
-----
helper.py:175:split_rc:TypeError: expected string or buffer

Traceback (most recent call last):
  File "/usr/bin/cnucnu", line 71, in <module>
    if not shell.cmdloop():
  File "/usr/lib64/python2.7/cmd.py", line 143, in cmdloop
    stop = self.postcmd(stop, line)
  File "/usr/lib/python2.7/site-packages/cnucnu/checkshell.py", line 127, in postcmd
    print "Latest:", self.package.latest_upstream
  File "/usr/lib/python2.7/site-packages/cnucnu/package_list.py", line 271, in latest_upstream
    self._latest_upstream = upstream_max(self.upstream_versions)
  File "/usr/lib/python2.7/site-packages/cnucnu/helper.py", line 199, in upstream_max
    list.sort(cmp=upstream_cmp)
  File "/usr/lib/python2.7/site-packages/cnucnu/helper.py", line 148, in upstream_cmp
    v1, rc1 = split_rc(v1)
  File "/usr/lib/python2.7/site-packages/cnucnu/helper.py", line 175, in split_rc
    match = RC.match(version)
TypeError: expected string or buffer

Local variables in innermost frame:
re: <module 're' from '/usr/lib64/python2.7/re.pyc'>
version: ('3', '3_001')
RC: <_sre.SRE_Pattern object at 0x26a4810>

How to reproduce
-----
1. cnucnu --shell
2. https://github.com/EttusResearch/UHD-Mirror/archives/master
3. release_0*([0-9]+)_0*([0-9]+_[0-9]+)
Comment 1 Jaroslav Škarvada 2011-12-02 08:03:46 EST
Created attachment 539622 [details]
File: backtrace
Comment 2 Jaroslav Škarvada 2011-12-02 09:40:31 EST
Created attachment 539671 [details]
Proposed patch

Patch to allow multiple groups in re. All groups are concat.
Comment 3 Jaroslav Škarvada 2011-12-02 11:00:23 EST
Created attachment 539693 [details]
Improved patch
Comment 4 Jaroslav Škarvada 2011-12-02 11:01:33 EST
This patch allows parsing of more complex patterns, e.g. the uhd from backtrace.
Comment 5 Till Maas 2013-03-04 14:57:39 EST
This feature has been added to cnucnu's git repository on fedorapeople and can be used now in the wiki. I will prepare an update for Fedora soon to allow to test it using the cnucnu shell.
Comment 6 Jaroslav Škarvada 2013-03-05 03:47:35 EST
Thanks.
Comment 7 Till Maas 2015-01-31 09:12:58 EST
FYI: cnucnu will be replaced by anitya/the-new-hotness soon:
https://github.com/fedora-infra/anitya
https://github.com/fedora-infra/the-new-hotness

Therefore a new update for Fedora does not make much sense.

Note You need to log in before you can comment on or make changes to this bug.