[tryton-debian-vcs] tryton-server branch upstream-3.2 updated. upstream/3.2.14-1-g049ecce
Mathias Behrle
tryton-debian-vcs at alioth.debian.org
Sat Apr 9 18:56:23 UTC 2016
The following commit has been merged in the upstream-3.2 branch:
https://alioth.debian.org/plugins/scmgit/cgi-bin/gitweb.cgi/?p=tryton/tryton-server.git;a=commitdiff;h=upstream/3.2.14-1-g049ecce
commit 049ecced5c4426f0d65484c5f2a702f80cf6eacb
Author: Mathias Behrle <mathiasb at m9s.biz>
Date: Sat Apr 9 20:10:52 2016 +0200
Adding upstream version 3.2.15.
Signed-off-by: Mathias Behrle <mathiasb at m9s.biz>
diff --git a/CHANGELOG b/CHANGELOG
index b43ee9a..2fa69be 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 3.2.15 - 2016-04-06
+* Bug fixes (see mercurial logs for details)
+
Version 3.2.14 - 2016-03-14
* Bug fixes (see mercurial logs for details)
* Limit the login size in LoginAttempt
diff --git a/PKG-INFO b/PKG-INFO
index 2a70b12..42c115b 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: trytond
-Version: 3.2.14
+Version: 3.2.15
Summary: Tryton server
Home-page: http://www.tryton.org/
Author: Tryton
diff --git a/trytond.egg-info/PKG-INFO b/trytond.egg-info/PKG-INFO
index 2a70b12..42c115b 100644
--- a/trytond.egg-info/PKG-INFO
+++ b/trytond.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: trytond
-Version: 3.2.14
+Version: 3.2.15
Summary: Tryton server
Home-page: http://www.tryton.org/
Author: Tryton
diff --git a/trytond.egg-info/requires.txt b/trytond.egg-info/requires.txt
index 25bd7b5..a71a64f 100644
--- a/trytond.egg-info/requires.txt
+++ b/trytond.egg-info/requires.txt
@@ -5,11 +5,14 @@ python-dateutil
polib
python-sql >= 0.2
-[cdecimal]
-cdecimal
+[BCrypt]
+bcrypt
-[unoconv]
-unoconv
+[Levenshtein]
+python-Levenshtein
+
+[MySQL]
+MySQL-python
[PostgreSQL]
psycopg2 >= 2.0
@@ -17,17 +20,14 @@ psycopg2 >= 2.0
[WebDAV]
PyWebDAV >= 0.9.8
-[simplejson]
-simplejson
-
-[MySQL]
-MySQL-python
+[cdecimal]
+cdecimal
-[BCrypt]
-bcrypt
+[graphviz]
+pydot
-[Levenshtein]
-python-Levenshtein
+[simplejson]
+simplejson
-[graphviz]
-pydot
\ No newline at end of file
+[unoconv]
+unoconv
diff --git a/trytond/backend/mysql/table.py b/trytond/backend/mysql/table.py
index 3fc878f..6d4956f 100644
--- a/trytond/backend/mysql/table.py
+++ b/trytond/backend/mysql/table.py
@@ -86,6 +86,7 @@ class TableHandler(TableHandlerInterface):
self.cursor.execute('ALTER TABLE `%s` '
'RENAME COLUMN `%s` TO `%s`'
% (self.table_name, old_name, new_name))
+ self._update_definitions()
elif exception and self.column_exist(new_name):
raise Exception('Unable to rename column %s.%s to %s.%s: '
'%s.%s already exist!'
diff --git a/trytond/backend/postgresql/table.py b/trytond/backend/postgresql/table.py
index be4478f..933c298 100644
--- a/trytond/backend/postgresql/table.py
+++ b/trytond/backend/postgresql/table.py
@@ -108,6 +108,7 @@ class TableHandler(TableHandlerInterface):
self.cursor.execute('ALTER TABLE "%s" '
'RENAME COLUMN "%s" TO "%s"'
% (self.table_name, old_name, new_name))
+ self._update_definitions()
elif exception and self.column_exist(new_name):
raise Exception('Unable to rename column %s.%s to %s.%s: '
'%s.%s already exist!'
diff --git a/trytond/backend/sqlite/table.py b/trytond/backend/sqlite/table.py
index f2fafcb..f7dc74c 100644
--- a/trytond/backend/sqlite/table.py
+++ b/trytond/backend/sqlite/table.py
@@ -113,6 +113,7 @@ class TableHandler(TableHandlerInterface):
','.join('"%s"' % x for x in old_columns) + ' ' +
'FROM "%s"') % (self.table_name, temp_table))
self.cursor.execute('DROP TABLE "%s"' % temp_table)
+ self._update_definitions()
elif exception and self.column_exist(new_name):
raise Exception('Unable to rename column %s.%s to %s.%s: '
'%s.%s already exist!'
diff --git a/trytond/ir/cron.py b/trytond/ir/cron.py
index 10f7e3f..31385b6 100644
--- a/trytond/ir/cron.py
+++ b/trytond/ir/cron.py
@@ -15,6 +15,7 @@ from ..transaction import Transaction
from ..pool import Pool
from .. import backend
from ..config import CONFIG
+from ..cache import Cache
__all__ = [
'Cron',
@@ -175,6 +176,7 @@ class Cron(ModelSQL, ModelView):
def run(cls, db_name):
now = datetime.datetime.now()
with Transaction().start(db_name, 0) as transaction:
+ Cache.clean(db_name)
transaction.cursor.lock(cls._table)
crons = cls.search([
('number_calls', '!=', 0),
@@ -207,3 +209,4 @@ class Cron(ModelSQL, ModelView):
tb_s = tb_s.decode('utf-8', 'ignore')
logger = logging.getLogger('cron')
logger.error('Exception:\n%s' % tb_s)
+ Cache.resets(db_name)
diff --git a/trytond/protocols/dispatcher.py b/trytond/protocols/dispatcher.py
index 8bb03e1..1268782 100644
--- a/trytond/protocols/dispatcher.py
+++ b/trytond/protocols/dispatcher.py
@@ -299,12 +299,14 @@ def restore(database_name, password, data, update=False):
logger = logging.getLogger('database')
security.check_super(password)
try:
- database = Database().connect()
+ database = Database(database_name).connect()
cursor = database.cursor()
cursor.close(close=True)
- raise Exception("Database already exists!")
+ existing = True
except Exception:
- pass
+ existing = False
+ if existing:
+ raise Exception('Database already exists!')
Database.restore(database_name, data)
logger.info('RESTORE DB: %s' % (database_name))
if update:
diff --git a/trytond/version.py b/trytond/version.py
index 8d92264..3227c3b 100644
--- a/trytond/version.py
+++ b/trytond/version.py
@@ -1,6 +1,6 @@
#This file is part of Tryton. The COPYRIGHT file at the top level of
#this repository contains the full copyright notices and license terms.
PACKAGE = "trytond"
-VERSION = "3.2.14"
+VERSION = "3.2.15"
LICENSE = "GPL-3"
WEBSITE = "http://www.tryton.org/"
--
tryton-server
More information about the tryton-debian-vcs
mailing list