Bug 1222759 - copr-cli don't work with coprs with dash '-' in name
Summary: copr-cli don't work with coprs with dash '-' in name
Keywords:
Status: CLOSED DUPLICATE of bug 1188022
Alias: None
Product: Fedora
Classification: Fedora
Component: copr-cli
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Suchý
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-05-19 05:43 UTC by Honza Horak
Modified: 2015-07-01 14:58 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-05-19 06:00:37 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Honza Horak 2015-05-19 05:43:18 UTC
Description of problem:
copr-cli build myuser/rh-mariadb100 http://url/to/file.src.rpm
Something went wrong:
Error: Copr with name rh does not exist.

Version-Release number of selected component (if applicable):
# rpm -q copr-cli
copr-cli-1.43-1.fc21.noarch


How reproducible:
every-time

Steps to Reproduce:
1. copr-cli build myuser/rh-mariadb100 http://url/to/file.src.rpm

Actual results:
Something went wrong:
Error: Copr with name rh does not exist.


Expected results:
build works

Additional info:
The same apply also for the user name (I expect it can also include dash)..

patch is simple:

# cat copr.patch 
--- main.py.orig	2015-05-19 07:30:37.241630312 +0200
+++ main.py	2015-05-19 07:30:04.799644087 +0200
@@ -153,7 +153,7 @@ class Commands(object):
 
         """
         copr = args.copr
-        m = re.match(r"(\w+)/(\w+)", copr)
+        m = re.match(r"([-\w]+)/([-\w]+)", copr)
         if m:
             username = m.group(1)
             copr = m.group(2)

Comment 1 Honza Horak 2015-05-19 05:45:58 UTC
Now I see the latest upstream source already includes the fix as r"(\w+)/(.*)" which seems sufficient. However in F21 it is still not fixed, which prevents me from building on F21.. please, consider backporting to f21 :)

Comment 2 Miroslav Suchý 2015-05-19 06:00:37 UTC
It is in testing since Sunday:
https://admin.fedoraproject.org/updates/FEDORA-2015-8352/copr-cli-1.44-1.fc21

*** This bug has been marked as a duplicate of bug 1188022 ***

Comment 3 Jakub Kadlčík 2015-07-01 14:58:28 UTC
*** Bug 1206651 has been marked as a duplicate of this bug. ***


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