[apycotlib] remove last remaining dependency to cubes (closes #3241607)
authorPaul Tonelli <paul.tonelli@logilab.fr>
Tue, 17 Sep 2013 13:46:21 +0200
changeset 1449 9dcf514fb32f
parent 1448 74288b916a1f
child 1450 2e257c617a67
[apycotlib] remove last remaining dependency to cubes (closes #3241607) we do not want apycotlib to depend on the apycot cube.
_apycotlib/__init__.py
_apycotlib/writer.py
debian/control
debian/rules
--- a/_apycotlib/__init__.py	Mon Sep 09 17:37:30 2013 +0200
+++ b/_apycotlib/__init__.py	Tue Sep 17 13:46:21 2013 +0200
@@ -28,8 +28,6 @@
 
 from logilab.common.textutils import splitstrip
 
-from cubes import narval # ensure narvalbot is importable
-
 # regitry of available repositories, preprocessors and checkers
 
 REGISTRY = {'repository': {},
--- a/_apycotlib/writer.py	Mon Sep 09 17:37:30 2013 +0200
+++ b/_apycotlib/writer.py	Tue Sep 17 13:46:21 2013 +0200
@@ -19,8 +19,6 @@
 
 from logilab.mtconverter import xml_escape
 
-from cubicweb import Binary
-
 REVERSE_SEVERITIES = {
     logging.DEBUG :   u'DEBUG',
     logging.INFO :    u'INFO',
@@ -216,7 +214,7 @@
             try:
                 tarball.add(archivedir)
                 tarball.close()
-                files = {'log': (archive, Binary(open(archivefpath,
+                files = {'log': (archive, StringIO(open(archivefpath,
                                  'rb').read()))}
                 self._cnxh.http_post(self.instance_url() + 'file-upload',
                                      files=files,
--- a/debian/control	Mon Sep 09 17:37:30 2013 +0200
+++ b/debian/control	Tue Sep 17 13:46:21 2013 +0200
@@ -13,7 +13,7 @@
 Package: cubicweb-apycot
 Architecture: all
 XB-Python-Version: ${python:Versions}
-Depends: ${misc:Depends}, ${python:Depends}, cubicweb-common (>= 3.14.0), cubicweb-vcsfile (>= 1.12), cubicweb-file (>= 1.8.2), cubicweb-narval (>= 3.0.2), pyro, python-pygments
+Depends: ${misc:Depends}, ${python:Depends}, cubicweb-common (>= 3.14.0), cubicweb-vcsfile (>= 1.12), cubicweb-file (>= 1.8.2), cubicweb-narval (>= 4.0.0), pyro, python-pygments
 Recommends: cubicweb-jqplot (>= 0.1.2)
 Suggests: cubicweb-tracker, cubicweb-nosylist (>= 0.5.0)
 Description: apycot component for the CubicWeb framework
@@ -25,7 +25,7 @@
 Package: narval-apycot
 Architecture: all
 XB-Python-Version: ${python:Versions}
-Depends: ${misc:Depends}, ${python:Depends}, cubicweb-apycot (= ${source:Version}), narval-bot
+Depends: ${misc:Depends}, ${python:Depends}, narval-bot (>= 4.0.0)
 Recommends: pylint, python-coverage, logilab-packaging
 Description: apycot extensions for the narval agent
  Provides a basic set of Narval actions for Continuous Integration.
--- a/debian/rules	Mon Sep 09 17:37:30 2013 +0200
+++ b/debian/rules	Tue Sep 17 13:46:21 2013 +0200
@@ -25,8 +25,6 @@
 	dh_installdirs -i
 	NO_SETUPTOOLS=1 python setup.py -q install --no-compile --prefix=debian/cubicweb-apycot/usr/
 	mv debian/cubicweb-apycot/usr/share/apycot debian/narval-apycot/usr/share
-	mv debian/cubicweb-apycot/usr/var/lib/narval debian/narval-apycot/var/lib/
-	rm -rf debian/cubicweb-apycot/usr/var
 	mv debian/cubicweb-apycot/usr/lib/python* debian/narval-apycot/usr/lib/