Merge lp:~zulcss/neutron/ftbfs-jan15 into lp:~ubuntu-server-dev/neutron/icehouse

Proposed by Chuck Short
Status: Merged
Approved by: Chuck Short
Approved revision: 218
Merged at revision: 218
Proposed branch: lp:~zulcss/neutron/ftbfs-jan15
Merge into: lp:~ubuntu-server-dev/neutron/icehouse
Diff against target: 125 lines (+77/-1)
5 files modified
debian/changelog (+7/-0)
debian/neutron-plugin-nicira.install (+1/-0)
debian/patches/series (+1/-0)
debian/patches/sql-alchemy-0.8.3-compat.patch (+67/-0)
debian/rules (+1/-1)
To merge this branch: bzr merge lp:~zulcss/neutron/ftbfs-jan15
Reviewer Review Type Date Requested Status
James Page Approve
Review via email: mp+201826@code.launchpad.net
To post a comment you must log in.
Revision history for this message
James Page (james-page) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2013-12-19 15:00:13 +0000
3+++ debian/changelog 2014-01-15 18:54:29 +0000
4@@ -1,5 +1,6 @@
5 neutron (1:2014.1~b1+master-0ubuntu1) UNRELEASED; urgency=low
6
7+ [ James Page ]
8 * Switch to using Modular Layer 2 plugin by default:
9 - d/control,neutron-plugin-ml2.install: Add ML2 plugin package
10 (LP: #1243147).
11@@ -30,6 +31,12 @@
12 * d/control,d/p/remove-jsonrpclib.patch: Add BD on python-jsonrpclib and drop
13 patch that excludes it from requirements.txt.
14
15+ [ Chuck Short ]
16+ * debian/rules: Run testr directly
17+ * debian/patches/sql-alchemy-0.8.3-compat.patch: Fix tests sqlalchemy 0.8.3
18+ compat.
19+ * debian/neturon-nicira.install: Add usr/bin/neutron-check-nsx-config.
20+
21 -- James Page <james.page@ubuntu.com> Tue, 10 Dec 2013 12:28:48 +0000
22
23 neutron (1:2014.1~b1-0ubuntu1) trusty; urgency=low
24
25=== modified file 'debian/neutron-plugin-nicira.install'
26--- debian/neutron-plugin-nicira.install 2013-07-15 17:45:17 +0000
27+++ debian/neutron-plugin-nicira.install 2014-01-15 18:54:29 +0000
28@@ -1,2 +1,3 @@
29 etc/neutron/plugins/nicira/* etc/neutron/plugins/nicira
30 usr/bin/neutron-check-nvp-config usr/bin
31+usr/bin/neutron-check-nsx-config usr/bin
32
33=== modified file 'debian/patches/series'
34--- debian/patches/series 2013-12-19 15:00:13 +0000
35+++ debian/patches/series 2014-01-15 18:54:29 +0000
36@@ -4,3 +4,4 @@
37 requirements.patch
38 disable-failing-metaplugin-tests.patch
39 disable-failing-cisco-test.patch
40+sql-alchemy-0.8.3-compat.patch
41
42=== added file 'debian/patches/sql-alchemy-0.8.3-compat.patch'
43--- debian/patches/sql-alchemy-0.8.3-compat.patch 1970-01-01 00:00:00 +0000
44+++ debian/patches/sql-alchemy-0.8.3-compat.patch 2014-01-15 18:54:29 +0000
45@@ -0,0 +1,67 @@
46+Description: Fix sqlalchemy 0.8.3 compat
47+Author: Chuck Short <zulcss@ubuntu.com>
48+Forwarded: No
49+diff --git a/neutron/openstack/common/db/sqlalchemy/session.py b/neutron/openstack/common/db/sqlalchemy/session.py
50+index 3279343..113424c 100644
51+--- a/neutron/openstack/common/db/sqlalchemy/session.py
52++++ b/neutron/openstack/common/db/sqlalchemy/session.py
53+@@ -441,6 +441,11 @@ def get_session(autocommit=True, expire_on_commit=False,
54+ # 1 column - (IntegrityError) column c1 is not unique
55+ # N columns - (IntegrityError) column c1, c2, ..., N are not unique
56+ #
57++# sqlite since 3.7.16:
58++# 1 column - (IntegrityError) UNIQUE constraint failed: k1
59++#
60++# N columns - (IntegrityError) UNIQUE constraint failed: k1, k2
61++#
62+ # postgres:
63+ # 1 column - (IntegrityError) duplicate key value violates unique
64+ # constraint "users_c1_key"
65+@@ -453,9 +458,10 @@ def get_session(autocommit=True, expire_on_commit=False,
66+ # N columns - (IntegrityError) (1062, "Duplicate entry 'values joined
67+ # with -' for key 'name_of_our_constraint'")
68+ _DUP_KEY_RE_DB = {
69+- "sqlite": re.compile(r"^.*columns?([^)]+)(is|are)\s+not\s+unique$"),
70+- "postgresql": re.compile(r"^.*duplicate\s+key.*\"([^\"]+)\"\s*\n.*$"),
71+- "mysql": re.compile(r"^.*\(1062,.*'([^\']+)'\"\)$")
72++ "sqlite": (re.compile(r"^.*columns?([^)]+)(is|are)\s+not\s+unique$"),
73++ re.compile(r"^.*UNIQUE\s+constraint\s+failed:\s+(.+)$")),
74++ "postgresql": (re.compile(r"^.*duplicate\s+key.*\"([^\"]+)\"\s*\n.*$"),),
75++ "mysql": (re.compile(r"^.*\(1062,.*'([^\']+)'\"\)$"),)
76+ }
77+
78+
79+@@ -480,10 +486,14 @@ def _raise_if_duplicate_entry_error(integrity_error, engine_name):
80+ if engine_name not in ["mysql", "sqlite", "postgresql"]:
81+ return
82+
83+- m = _DUP_KEY_RE_DB[engine_name].match(integrity_error.message)
84+- if not m:
85++ for pattern in _DUP_KEY_RE_DB[engine_name]:
86++ match = pattern.match(integrity_error.message)
87++ if match:
88++ break
89++ else:
90+ return
91+- columns = m.group(1)
92++
93++ columns = match.group(1)
94+
95+ if engine_name == "sqlite":
96+ columns = columns.strip().split(", ")
97+diff --git a/run_tests.sh b/run_tests.sh
98+index cc17124..06934e9 100755
99+--- a/run_tests.sh
100++++ b/run_tests.sh
101+@@ -162,7 +162,7 @@ function run_pep8 {
102+ }
103+
104+
105+-TESTRTESTS="python setup.py testr"
106++TESTRTESTS="python -m neutron.openstack.common.lockutils python setup.py testr"
107+
108+ if [ $never_venv -eq 0 ]
109+ then
110+--
111+1.8.5.2
112+
113
114=== modified file 'debian/rules'
115--- debian/rules 2013-12-19 14:08:21 +0000
116+++ debian/rules 2014-01-15 18:54:29 +0000
117@@ -25,7 +25,7 @@
118 # with a core_plugin being set.
119 patch -p1 -R < debian/patches/fix-quantum-configuration.patch
120 # Set a reasonable level of concurrency
121- ./run_tests.sh -N -P --concurrency=4
122+ python -m neutron.openstack.common.lockutils python setup.py testr
123 # Patch configuration file after testing
124 patch -p1 < debian/patches/fix-quantum-configuration.patch
125 endif

Subscribers

People subscribed via source and target branches