Your message dated Tue, 27 Aug 2019 01:00:32 +0000
with message-id <[email protected]>
and subject line Bug#935836: Removed package(s) from unstable
has caused the Debian Bug report #659143,
regarding Add multi repository support
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
659143: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=659143
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: rebuildd
Tags: patch

I've added multi repository support to my local rebuildd system, now
I'm pushing it upstream.  We use rebuildd along side pbuilder and
reprepro and need the ability to run multiple local reprepro
repositories.  The attached patch adds support for it and now rebuildd
knows which repository submit the package to build.

-- 
Paul Belanger | dCAP
Polybeacon | Consultant
Jabber: [email protected] | IRC: pabelanger (Freenode) |
Blog: http://blog.polybeacon.com | Twitter: http://twitter.com/pabelanger
diff --git a/rebuildd-job b/rebuildd-job
index 6074455..002047a 100755
--- a/rebuildd-job
+++ b/rebuildd-job
@@ -73,8 +73,10 @@ def add():
             Rebuildd().add_job(args[0], args[1], args[2], args[3], mailto=None, arch=args[4])
         if len(args) == 6:
             Rebuildd().add_job(args[0], args[1], args[2], args[3], mailto=args[5], arch=args[4])
+        if len(args) == 7:
+            Rebuildd().add_job(args[0], args[1], args[2], args[3], mailto=args[5], arch=args[4], repo=args[6])
     if empty:
-        print "E: usage: %s\n   read <package> <version> <priority> <dist> [arch] [mailto] from stdin" % sys.argv[0]
+        print "E: usage: %s\n   read <package> <version> <priority> <dist> [arch] [mailto] [repo] from stdin" % sys.argv[0]
         sys.exit(1)
 
 def add_quinn_diff(dist):
diff --git a/rebuildd/Distribution.py b/rebuildd/Distribution.py
index ee025e1..b93b157 100644
--- a/rebuildd/Distribution.py
+++ b/rebuildd/Distribution.py
@@ -40,7 +40,7 @@ class Distribution(object):
 
         try:
 	    args = { 'd': self.name, 'a': self.arch, 'v': package.version, \
-                'p': package.name }
+                'p': package.name, 'r': package.repo }
             t = Template(RebuilddConfig().get('build', 'source_cmd'))
 	    return t.safe_substitute(**args)
         except TypeError, error:
@@ -54,7 +54,7 @@ class Distribution(object):
         try:
             index = package.version.index(":")
             args = { 'd': self.name, 'a': self.arch, \
-                'v': package.version[index+1:], 'p': package.name }
+                'v': package.version[index + 1:], 'p': package.name, 'r': package.repo }
             t = Template(RebuilddConfig().get('build', 'build_cmd'))
 	    return t.safe_substitute(**args)
         except ValueError:
@@ -62,7 +62,7 @@ class Distribution(object):
 
         try:
             args = { 'd': self.name, 'a': self.arch, \
-                'v': package.version, 'p': package.name }
+                'v': package.version, 'p': package.name, 'r': package.repo }
             t = Template(RebuilddConfig().get('build', 'build_cmd'))
 	    return t.safe_substitute(**args)
         except TypeError, error:
@@ -77,7 +77,7 @@ class Distribution(object):
             return None
         try:
             args = { 'd': self.name, 'a': self.arch, \
-                'v': package.version, 'p': package.name }
+                'v': package.version, 'p': package.name, 'r': package.repo }
             t = Template(cmd)
 	    return t.safe_substitute(**args)
         except TypeError, error:
diff --git a/rebuildd/Job.py b/rebuildd/Job.py
index 61ea930..263bbbb 100644
--- a/rebuildd/Job.py
+++ b/rebuildd/Job.py
@@ -57,8 +57,8 @@ class Job(threading.Thread, sqlobject.SQLObject):
         """Override setattr to log build status changes"""
 
         if name == "status":
-            RebuilddLog.info("Job %s for %s_%s on %s/%s changed status from %s to %s"\
-                    % (self.id, self.package.name, self.package.version, 
+            RebuilddLog.info("Job %s for %s_%s, from %s, on %s/%s changed status from %s to %s"\
+                    % (self.id, self.package.name, self.package.version, self.package.repo,
                        self.dist, self.arch,
                        JobStatus.whatis(self.status),
                        JobStatus.whatis(value)))
@@ -88,8 +88,8 @@ class Job(threading.Thread, sqlobject.SQLObject):
 
         try:
             with open(self.logfile, "w") as build_log:
-                build_log.write("Automatic build of %s_%s on %s for %s/%s by rebuildd %s\n" % \
-                                 (self.package.name, self.package.version,
+                build_log.write("Automatic build of %s_%s, from %s, on %s for %s/%s by rebuildd %s\n" % \
+                                 (self.package.name, self.package.version, self.package.repo,
                                   self.host, self.dist, self.arch, __version__))
                 build_log.write("Build started at %s\n" % self.build_start)
                 build_log.write("******************************************************************************\n")
@@ -208,10 +208,11 @@ class Job(threading.Thread, sqlobject.SQLObject):
             msg['To'] = RebuilddConfig().get('mail', 'mailto')
         msg['From'] = RebuilddConfig().get('mail', 'from')
         msg['Subject'] = RebuilddConfig().get('mail', 'subject_prefix') + \
-                                 " Log for %s build of %s_%s on %s/%s" % \
+                                 " Log for %s build of %s_%s, from %s, on %s/%s" % \
                                  (bstatus,
                                   self.package.name, 
                                   self.package.version,
+                                  self.package.repo,
                                   self.dist,
                                   self.arch)
         msg['X-Rebuildd-Version'] = __version__
@@ -247,8 +248,8 @@ class Job(threading.Thread, sqlobject.SQLObject):
         return True
 
     def __str__(self):
-        return "I: Job %s for %s_%s is status %s on %s for %s/%s" % \
-                (self.id, self.package.name, self.package.version, self.host,
+        return "I: Job %s for %s_%s, from %s, is status %s on %s for %s/%s" % \
+                (self.id, self.package.name, self.package.version, self.package.repo, self.host,
                  JobStatus.whatis(self.status), self.dist, self.arch)
 
     def is_allowed_to_build(self):
diff --git a/rebuildd/Package.py b/rebuildd/Package.py
index d14c993..7da4b76 100644
--- a/rebuildd/Package.py
+++ b/rebuildd/Package.py
@@ -27,6 +27,7 @@ class Package(sqlobject.SQLObject):
     name = sqlobject.StringCol() 
     version = sqlobject.StringCol(default=None) 
     priority = sqlobject.StringCol(default=None)
+    repo = sqlobject.StringCol(default=None)
 
     @staticmethod
     def version_compare(a, b):
diff --git a/rebuildd/Rebuildd.py b/rebuildd/Rebuildd.py
index 1e56e1c..54482cc 100644
--- a/rebuildd/Rebuildd.py
+++ b/rebuildd/Rebuildd.py
@@ -286,7 +286,7 @@ class Rebuildd(object):
 
         return True
 
-    def add_job(self, name, version, priority, dist, mailto=None, arch=None):
+    def add_job(self, name, version, priority, dist, mailto=None, arch=None, repo=None):
         """Add a job"""
 
         if not arch:
@@ -295,18 +295,18 @@ class Rebuildd(object):
         if not Dists().get_dist(dist, arch):
             return False
 
-        pkgs = Package.selectBy(name=name, version=version)
+        pkgs = Package.selectBy(name=name, version=version, repo=repo)
         if pkgs.count():
             # If several packages exists, just take the first
             pkg = pkgs[0]
         else:
             # Maybe we found no packages, so create a brand new one!
-            pkg = Package(name=name, version=version, priority=priority)
+            pkg = Package(name=name, version=version, priority=priority, repo=repo)
 
         jobs_count = Job.selectBy(package=pkg, dist=dist, arch=arch, mailto=mailto, status=JobStatus.WAIT).count()
         if jobs_count:
-            RebuilddLog.error("Job already existing for %s_%s on %s/%s, don't adding it" \
-                           % (pkg.name, pkg.version, dist, arch))
+            RebuilddLog.error("Job already existing for %s_%s, from %s, on %s/%s, don't adding it" \
+                           % (pkg.name, pkg.version, pkg.repo, dist, arch))
             return False
 
         job = Job(package=pkg, dist=dist, arch=arch)
@@ -314,8 +314,8 @@ class Rebuildd(object):
         job.arch = arch
         job.mailto = mailto
 
-        RebuilddLog.info("Added job for %s_%s on %s/%s for %s" \
-                      % (name, version, dist, arch, mailto))
+        RebuilddLog.info("Added job for %s_%s, from %s, on %s/%s for %s" \
+                      % (name, version, repo, dist, arch, mailto))
         return True
 
     def add_deps(self, job_id, dependency_ids):
diff --git a/rebuildd/RebuilddNetworkClient.py b/rebuildd/RebuilddNetworkClient.py
index 095e611..00fd93e 100644
--- a/rebuildd/RebuilddNetworkClient.py
+++ b/rebuildd/RebuilddNetworkClient.py
@@ -164,6 +164,15 @@ class RebuilddNetworkClient(threading.Thread):
                                         dist=args[4], 
                                         arch=args[5],
                                         mailto=args[6])
+
+        if len(args) == 8:
+            ret = self.rebuildd.add_job(name=args[1], 
+                                        version=args[2],
+                                        priority=args[3],
+                                        dist=args[4], 
+                                        arch=args[5],
+                                        mailto=args[6],
+                                        repo=args[7])
         
         if ret:
             return "I: job added\n"

--- End Message ---
--- Begin Message ---
Version: 0.4.2+rm

Dear submitter,

as the package rebuildd has just been removed from the Debian archive
unstable we hereby close the associated bug reports.  We are sorry
that we couldn't deal with your issue properly.

For details on the removal, please see https://bugs.debian.org/935836

The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.

This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing
[email protected].

Debian distribution maintenance software
pp.
Scott Kitterman (the ftpmaster behind the curtain)

--- End Message ---

Reply via email to