| |
@@ -311,13 +311,14 @@
|
| |
def handle_rawhide_to_release(self, result):
|
| |
data = json.loads(self.data["data"])
|
| |
try:
|
| |
- chrootdir = os.path.join(self.opts.destdir, data["user"], data["copr"], data["dest_chroot"])
|
| |
+ chrootdir = os.path.join(self.opts.destdir, data["ownername"], data["projectname"], data["dest_chroot"])
|
| |
if not os.path.exists(chrootdir):
|
| |
self.log.debug("Create directory: %s", chrootdir)
|
| |
os.makedirs(chrootdir)
|
| |
|
| |
for build in data["builds"]:
|
| |
- srcdir = os.path.join(self.opts.destdir, data["user"], data["copr"], data["rawhide_chroot"], build)
|
| |
+ srcdir = os.path.join(self.opts.destdir, data["ownername"],
|
| |
+ data["projectname"], data["rawhide_chroot"], build)
|
| |
if os.path.exists(srcdir):
|
| |
destdir = os.path.join(chrootdir, build)
|
| |
self.log.debug("Copy directory: %s as %s", srcdir, destdir)
|
| |
@@ -438,7 +439,7 @@
|
| |
|
| |
def run(self):
|
| |
""" Handle action (other then builds) - like rename or delete of project """
|
| |
- self.log.info("Executing: %s", self)
|
| |
+ self.log.info("Executing: %s", str(self))
|
| |
|
| |
result = Munch()
|
| |
result.id = self.data["id"]
|
| |
Our rawhide_to_release command stopped working after b15e450.
That commit changed action data, that is sent to the backend.
It used to send build results dirs, that were constructed from build ID and package name.
b15e450 changed it and from that point, the sent result dirs are just build IDs.
However, backend data structure didn't change and neither the backend code.
This PR restores this particular behavior previous to the noted commit.
Also, a69a743 somehow messed with
ownername
andprojectname
attributes.We can't just send
copr.user.name
because data for group projects are storedin
@group/project
directories. And finally, I believe, thatownername
andprojectname
are better names than
user
andcopr
, because they are more explicit.