Added python-gitlab3 ebuild

git-svn-id: svn+ssh://svnintern.kmrc.de/projects/gentoo/iwm-overlay@34768 cbe59ace-07ea-0310-918e-868702b5370d
This commit is contained in:
Torsten Kurbad 2015-10-08 15:49:09 +00:00
parent 92a1341c6e
commit f55eb6dcfd
6 changed files with 210 additions and 0 deletions

View File

@ -0,0 +1,6 @@
AUX axiom-0.5.30-sqlite3.patch 1303 SHA256 04a168a9df2f288a25b4989ddba35c8fd2823902bbe9f5987979f8c12c6188c5 SHA512 920211a621837b9ac284e143147ab37bf5ad9e927c472be6aa4c3616858f0069bce97d1d02e0802b142fabd775e7c9adc37c73328b0ce4d57e94838dc67c0d9b WHIRLPOOL 40e7587720a87d54ac0c23b641ac6f5c4328b55f00e56504b508eadced981e6035506fadfe233b517ec2319891d40924d804420ed8054354cd3c4b70a14810b9
AUX axiom-0.5.30-sqlite3_3.6.4.patch 1526 SHA256 1ec993226d9e71008780a0d17aac830ffc169d3b86c66031c970157741cecf2a SHA512 a147cc8a221f05bdfc7bca0f84a273d6fda94404c16e8d6bccf89bb7762ccf4dcbe7e84b4c459843900ebb7a9f82c82b564222b570774fcf0fdf57f468eaa999 WHIRLPOOL 2a3bf8d53f10db5ccfe84afc10449cca887dabaebc491d4d41b63b0c02142543382e78beeb75ea8f92c6a80fd1eecf7446928e33f79d322d8e3c6ebe08c4e53b
AUX axiom-0.6.0-disable-tests.patch 3342 SHA256 5e658da7f6735dfcdcbb89a058fcc97a68dfae6792cfb6c4ef162d2152d714b4 SHA512 4fb4ce59cd3d4247b6d10d552d8adab40127dd0775d586ca21cad7e5fe655716ff0913fc63f7f72f92829fc8017d02526219bebfb34e5d7f8b848f04ac8cc233 WHIRLPOOL 9c3273e99b1ad85e3b46717970525dfa5492ae3446d3d15bb281fc59005be6d195ca58ac87c43bd70793d40dc18b77e3d1b06851a5c0c34fb03905d81947b0a1
DIST gitlab3-0.5.4.tar.gz 8624 SHA256 f3ef736ae8d2754064b06cfbbd6039480859a58c9a541007d358f8672deb666e SHA512 792472334b16688052461ddc7981a48a48a81f0ac6df9846d4eb9f1632f54b361a4c1c32a45298350c6dc122b8358a70ddeddc0e36b5ee9e7dc2eabcc6e8aec9 WHIRLPOOL 4f3bd9077889def67c76d3fa7c798ece3bed854a93d5adf172180a913e38a3aa48fa08e0549f257dc2b013d321d2c89ac062b531141470fb5e068f446f34f07d
EBUILD gitlab3-0.5.4.ebuild 455 SHA256 fac0cb56a4ef13ee08f61de93f8d0f2cb9dba6773ff775f7b1fa57b82c5e243a SHA512 1f898afe81f164917da5af89bd1d9b6646be56026f711a0d37be0c7cea15db7430a882c80392aa742333262635ef2af8304332645289cbecd96b3c26b9f4e5c3 WHIRLPOOL 6c8164d32b5fa7fca723aeb819bb6a4253fd19df634995c86d0be5b490b81376a2aa16b6475af54d3e4feb004367def70844e89258dc6bcb89a8a8cceb01396e
MISC metadata.xml 666 SHA256 7cfd6ed86ce268d96227b39d9d5fe2cf2a127b781231902626e77a52ce8c219a SHA512 8b2edd139194c734ba455056b1d9906f5c2912dde16ff9ec9f11b7c295df8abd4e63f208dfd20b90423e716e3dc4f8b000840a616417869e84914c9cdc979497 WHIRLPOOL 08deac63a1cfa4f3ec7df7d4af79ed5c5786dfeb4b74e0659f45a28c66772015a202b91110eeca867126846e5b2b88bd57561a80d8b93a01aff7fc2a1fde66cc

View File

@ -0,0 +1,45 @@
--- axiom/_pysqlite2.py 2006-07-05 18:31:18.000000000 +0300
+++ axiom/_pysqlite2.py 2007-11-02 05:10:45.000000000 +0200
@@ -8,7 +8,11 @@
"""
import time
-from pysqlite2 import dbapi2
+# Use python2.5's sqlite3 if avaliable
+try:
+ from sqlite3 import dbapi2
+except:
+ from pysqlite2 import dbapi2
from twisted.python import log
--- axiom/test/test_pysqlite2.py 2006-07-02 19:23:40.000000000 +0300
+++ axiom/test/test_pysqlite2.py 2007-11-02 05:39:44.000000000 +0200
@@ -2,7 +2,11 @@
Test cases for PySQLite2-specific parts of the backend.
"""
-from pysqlite2.dbapi2 import OperationalError
+# Use python2.5's sqlite3 if avaliable
+try:
+ from sqlite3.dbapi2 import OperationalError
+except:
+ from pysqlite2.dbapi2 import OperationalError
from twisted.trial.unittest import TestCase
--- axiom/test/test_xatop.py 2007-02-23 02:09:19.000000000 +0200
+++ axiom/test/test_xatop.py 2007-11-02 05:38:48.000000000 +0200
@@ -9,7 +9,11 @@
from axiom import attributes, item, store, errors
from axiom.errors import ItemNotFound
-from pysqlite2.dbapi2 import sqlite_version_info
+# Use python2.5's sqlite3 if avaliable
+try:
+ from sqlite3.dbapi2 import sqlite_version_info
+except:
+ from pysqlite2.dbapi2 import sqlite_version_info
class RevertException(Exception):

View File

@ -0,0 +1,36 @@
--- axiom/_schema.py (revision 17031)
+++ axiom/_schema.py (working copy)
@@ -28,7 +28,7 @@
CREATE TABLE *DATABASE*.axiom_attributes (
type_id INTEGER,
row_offset INTEGER,
- indexed BOOLEAN,
+ "indexed" BOOLEAN,
sqltype VARCHAR,
allow_none BOOLEAN,
pythontype VARCHAR,
@@ -47,13 +47,13 @@
HAS_SCHEMA_FEATURE = ("SELECT COUNT(oid) FROM *DATABASE*.sqlite_master "
"WHERE type = ? AND name = ?")
-IDENTIFYING_SCHEMA = ('SELECT indexed, sqltype, allow_none, attribute '
+IDENTIFYING_SCHEMA = ('SELECT "indexed", sqltype, allow_none, attribute '
'FROM *DATABASE*.axiom_attributes WHERE type_id = ? '
'ORDER BY row_offset')
ADD_SCHEMA_ATTRIBUTE = (
'INSERT INTO *DATABASE*.axiom_attributes '
- '(type_id, row_offset, indexed, sqltype, allow_none, attribute, docstring, pythontype) '
+ '(type_id, row_offset, "indexed", sqltype, allow_none, attribute, docstring, pythontype) '
'VALUES (?, ?, ?, ?, ?, ?, ?, ?)')
ALL_TYPES = 'SELECT oid, module, typename, version FROM *DATABASE*.axiom_types'
@@ -61,7 +61,7 @@
GET_GREATER_VERSIONS_OF_TYPE = ('SELECT version FROM *DATABASE*.axiom_types '
'WHERE typename = ? AND version > ?')
-SCHEMA_FOR_TYPE = ('SELECT indexed, pythontype, attribute, docstring '
+SCHEMA_FOR_TYPE = ('SELECT "indexed", pythontype, attribute, docstring '
'FROM *DATABASE*.axiom_attributes '
'WHERE type_id = ?')

View File

@ -0,0 +1,89 @@
--- test/lib/axiom/test/test_query.py.orig 2015-07-21 10:15:57.441000000 +0000
+++ test/lib/axiom/test/test_query.py 2015-07-21 10:16:36.356000000 +0000
@@ -1043,46 +1043,46 @@
SecondType(store=self.store)
- def test_firstTableOuterLoop(self):
- """
- Test that in a two table query, the table which appears first in the
- result of the getInvolvedTables method of the comparison used is the
- one which the outer join loop iterates over.
-
- Test this by inserting rows into the first table and checking that the
- number of bytecodes executed increased.
- """
- counter = QueryCounter(self.store)
- counts = []
- for c in range(10):
- counts.append(counter.measure(list, self.query))
- FirstType(store=self.store)
-
- # Make sure they're not all the same
- self.assertEqual(len(set(counts)), len(counts))
-
- # Make sure they're increasing
- self.assertEqual(counts, sorted(counts))
-
-
- def test_secondTableInnerLoop(self):
- """
- Like L{test_firstTableOuterLoop} but for the second table being
- iterated over by the inner loop.
-
- This creates more rows in the second table while still performing a
- query for which no rows in the first table satisfy the WHERE
- condition. This should mean that rows from the second table are
- never examined.
- """
- counter = QueryCounter(self.store)
- count = None
- for i in range(10):
- c = counter.measure(list, self.query)
- if count is None:
- count = c
- self.assertEqual(count, c)
- SecondType(store=self.store)
+ #def test_firstTableOuterLoop(self):
+ # """
+ # Test that in a two table query, the table which appears first in the
+ # result of the getInvolvedTables method of the comparison used is the
+ # one which the outer join loop iterates over.
+
+ # Test this by inserting rows into the first table and checking that the
+ # number of bytecodes executed increased.
+ # """
+ # counter = QueryCounter(self.store)
+ # counts = []
+ # for c in range(10):
+ # counts.append(counter.measure(list, self.query))
+ # FirstType(store=self.store)
+
+ # # Make sure they're not all the same
+ # self.assertEqual(len(set(counts)), len(counts))
+
+ # # Make sure they're increasing
+ # self.assertEqual(counts, sorted(counts))
+
+
+ #def test_secondTableInnerLoop(self):
+ # """
+ # Like L{test_firstTableOuterLoop} but for the second table being
+ # iterated over by the inner loop.
+
+ # This creates more rows in the second table while still performing a
+ # query for which no rows in the first table satisfy the WHERE
+ # condition. This should mean that rows from the second table are
+ # never examined.
+ # """
+ # counter = QueryCounter(self.store)
+ # count = None
+ # for i in range(10):
+ # c = counter.measure(list, self.query)
+ # if count is None:
+ # count = c
+ # self.assertEqual(count, c)
+ # SecondType(store=self.store)
class AndOrQueries(QueryingTestCase):

View File

@ -0,0 +1,20 @@
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI="5"
PYTHON_COMPAT=( python2_7 )
inherit distutils-r1
DESCRIPTION="A Python wrapper for GitLab API v3"
HOMEPAGE="https://github.com/alexvh/python-gitlab3"
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86"
IUSE=""
RDEPEND="dev-python/requests"
DEPEND="${RDEPEND}"

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<herd>python</herd>
<longdescription lang="en">Axiom is an object database, or alternatively, an object-relational
mapper. Its primary goal is to provide an object-oriented layer with
what we consider to be the key aspects of OO, i.e. polymorphism and
message dispatch, without hindering the power of an RDBMS. It is
designed to &quot;feel pythonic&quot;, without encouraging the typical ORM
behavior such as potato programming.</longdescription>
<upstream>
<remote-id type="pypi">Axiom</remote-id>
</upstream>
</pkgmetadata>