Hello community,

here is the log from the commit of package proteus for openSUSE:Factory checked 
in at 2019-01-21 10:48:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/proteus (Old)
 and      /work/SRC/openSUSE:Factory/.proteus.new.28833 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "proteus"

Mon Jan 21 10:48:57 2019 rev:9 rq:664353 version:4.6.5

Changes:
--------
--- /work/SRC/openSUSE:Factory/proteus/proteus.changes  2018-09-10 
12:32:20.626606945 +0200
+++ /work/SRC/openSUSE:Factory/.proteus.new.28833/proteus.changes       
2019-01-21 10:49:26.900085626 +0100
@@ -1,0 +2,5 @@
+Mon Dec 10 19:29:29 UTC 2018 - Axel Braun <[email protected]>
+
+- Version 4.6.5 - Bugfix Release
+
+-------------------------------------------------------------------
@@ -44,0 +50 @@
+

Old:
----
  proteus-4.2.4.tar.gz

New:
----
  proteus-4.6.5.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ proteus.spec ++++++
--- /var/tmp/diff_new_pack.kqMOq5/_old  2019-01-21 10:49:28.292083928 +0100
+++ /var/tmp/diff_new_pack.kqMOq5/_new  2019-01-21 10:49:28.296083923 +0100
@@ -2,7 +2,7 @@
 # spec file for package proteus
 #
 # Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
-# Copyright (c) 2016 Dr. Axel Braun
+# Copyright (c) 2017-2018 Dr. Axel Braun
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -13,13 +13,13 @@
 # license that conforms to the Open Source Definition (Version 1.9)
 # published by the Open Source Initiative.
 
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
 
-%define majorver 4.2
+%define majorver 4.6
 Name:           proteus
-Version:        %{majorver}.4
+Version:        %{majorver}.5
 Release:        0
 Summary:        A library to access Tryton's modules like a client
 License:        GPL-3.0-or-later
@@ -55,7 +55,8 @@
 
 %files 
 %defattr(-,root,root)
-%doc README LICENSE
+%doc README 
+%license LICENSE
 %{python_sitelib}/*
 
 %changelog

++++++ _service ++++++
--- /var/tmp/diff_new_pack.kqMOq5/_old  2019-01-21 10:49:28.320083893 +0100
+++ /var/tmp/diff_new_pack.kqMOq5/_new  2019-01-21 10:49:28.324083888 +0100
@@ -1,3 +1,4 @@
 <services>
   
-<service name="download_files" mode="localonly"/></services>
\ No newline at end of file
+<service name="download_files" mode="localonly" />
+</services>

++++++ proteus-4.2.4.tar.gz -> proteus-4.6.5.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/.drone.yml new/proteus-4.6.5/.drone.yml
--- old/proteus-4.2.4/.drone.yml        2016-11-28 18:43:52.000000000 +0100
+++ new/proteus-4.6.5/.drone.yml        2018-08-20 22:55:18.000000000 +0200
@@ -1,4 +1,23 @@
-image: python:all
-script:
-  - pip install tox pydot
-  - tox -e "py27,py33,py34,py35" --skip-missing-interpreters
+clone:
+    hg:
+        image: plugins/hg
+
+pipeline:
+    tox:
+        image: ${IMAGE}
+        commands:
+            - pip install tox pydot
+            - tox -e "${TOXENV}"
+        volumes:
+             - cache:/root/.cache
+
+matrix:
+    include:
+        - IMAGE: python:2.7
+          TOXENV: py27
+        - IMAGE: python:3.4
+          TOXENV: py34
+        - IMAGE: python:3.5
+          TOXENV: py35
+        - IMAGE: python:3.6
+          TOXENV: py36
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/.hgtags new/proteus-4.6.5/.hgtags
--- old/proteus-4.2.4/.hgtags   2018-07-05 11:53:57.000000000 +0200
+++ new/proteus-4.6.5/.hgtags   2018-12-03 00:47:53.000000000 +0100
@@ -11,7 +11,10 @@
 1e741a18e2a1f29fcc66e9ab4878554a4e63a355 3.8.0
 403f21dd1bb7059a0928c46c8b21a97c14f9c720 4.0.0
 d5b1e8f047748526d9a2cd354da0e86d617ec4c7 4.2.0
-e93fec45318a3c7bf3657f65e61ef2f8a7af2658 4.2.1
-1403ab2878cb87c6173d863295e73632102e56ba 4.2.2
-f0c92cc914763443499e98a1dc0e2f4256ed76a6 4.2.3
-06918e9a2a4fa841e07c89fb6247f2154d5ebf60 4.2.4
+365af7e74c2baae38e96bc0afb1deae2d2b44ac0 4.4.0
+cd4731fb373698d480a625a286de776a0b9bdc6e 4.6.0
+a619bdc53ae509a3bbe9386bfde8fbf8ec16fa9c 4.6.1
+9e48f91c2c06819554ef34cabd827e19f456a9f9 4.6.2
+bf508cfe1024bfe98b86fb67fe90f89c568b9b02 4.6.3
+1357255a797f53827a663cd4ea3d08a5448ab9df 4.6.4
+4b75c46d9bf62a307b5c6e23a13e5500a6f1f24f 4.6.5
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/CHANGELOG new/proteus-4.6.5/CHANGELOG
--- old/proteus-4.2.4/CHANGELOG 2018-07-05 11:53:57.000000000 +0200
+++ new/proteus-4.6.5/CHANGELOG 2018-12-03 00:47:53.000000000 +0100
@@ -1,13 +1,25 @@
-Version 4.2.4 - 2018-07-05
+Version 4.6.5 - 2018-12-02
 * Bug fixes (see mercurial logs for details)
 
-Version 4.2.3 - 2018-05-07
+Version 4.6.4 - 2018-08-03
 * Bug fixes (see mercurial logs for details)
 
-Version 4.2.2 - 2018-03-01
+Version 4.6.3 - 2018-07-05
 * Bug fixes (see mercurial logs for details)
 
-Version 4.2.1 - 2017-11-07
+Version 4.6.2 - 2018-05-07
+* Bug fixes (see mercurial logs for details)
+
+Version 4.6.1 - 2018-03-01
+* Bug fixes (see mercurial logs for details)
+
+Version 4.6.0 - 2017-10-30
+* Bug fixes (see mercurial logs for details)
+* Add set_sequence method to ModelList
+* Add __int__ to Model
+* Allow to use keyword arguments with trytond configuration
+
+Version 4.4.0 - 2017-05-01
 * Bug fixes (see mercurial logs for details)
 
 Version 4.2.0 - 2016-11-28
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/PKG-INFO new/proteus-4.6.5/PKG-INFO
--- old/proteus-4.2.4/PKG-INFO  2018-07-05 11:53:58.000000000 +0200
+++ new/proteus-4.6.5/PKG-INFO  2018-12-03 00:47:54.000000000 +0100
@@ -1,12 +1,12 @@
 Metadata-Version: 1.1
 Name: proteus
-Version: 4.2.4
+Version: 4.6.5
 Summary: Library to access Tryton server as a client
 Home-page: http://www.tryton.org/
 Author: Tryton
 Author-email: [email protected]
 License: LGPL-3
-Download-URL: http://downloads.tryton.org/4.2/
+Download-URL: http://downloads.tryton.org/4.6/
 Description-Content-Type: UNKNOWN
 Description: proteus
         =======
@@ -116,6 +116,28 @@
         
             >>> type_, data, print_, name = label.execute([party], {})
         
+        Sorting addresses and register order
+        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+        
+        Addresses are ordered by sequence which means they can be stored 
following a
+        specific order. The `set_sequence` method stores the current order.
+        
+            >>> address = party.addresses.new(zip='69')
+            >>> party.save()
+            >>> address = party.addresses.new(zip='23')
+            >>> party.save()
+        
+        Now changing the order.
+        
+            >>> reversed_addresses = list(reversed(party.addresses))
+            >>> while party.addresses:
+            ...     _ = party.addresses.pop()
+            >>> party.addresses.extend(reversed_addresses)
+            >>> party.addresses.set_sequence()
+            >>> party.save()
+            >>> party.addresses == reversed_addresses
+            True
+        
         Support
         -------
         
@@ -153,9 +175,9 @@
 Classifier: License :: OSI Approved :: GNU Library or Lesser General Public 
License (LGPL)
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python :: 2.7
-Classifier: Programming Language :: Python :: 3.3
 Classifier: Programming Language :: Python :: 3.4
 Classifier: Programming Language :: Python :: 3.5
+Classifier: Programming Language :: Python :: 3.6
 Classifier: Programming Language :: Python :: Implementation :: CPython
 Classifier: Programming Language :: Python :: Implementation :: PyPy
 Classifier: Topic :: Office/Business
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/README new/proteus-4.6.5/README
--- old/proteus-4.2.4/README    2016-11-28 18:43:52.000000000 +0100
+++ new/proteus-4.6.5/README    2018-08-20 22:55:18.000000000 +0200
@@ -106,6 +106,28 @@
 
     >>> type_, data, print_, name = label.execute([party], {})
 
+Sorting addresses and register order
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Addresses are ordered by sequence which means they can be stored following a
+specific order. The `set_sequence` method stores the current order.
+
+    >>> address = party.addresses.new(zip='69')
+    >>> party.save()
+    >>> address = party.addresses.new(zip='23')
+    >>> party.save()
+
+Now changing the order.
+
+    >>> reversed_addresses = list(reversed(party.addresses))
+    >>> while party.addresses:
+    ...     _ = party.addresses.pop()
+    >>> party.addresses.extend(reversed_addresses)
+    >>> party.addresses.set_sequence()
+    >>> party.save()
+    >>> party.addresses == reversed_addresses
+    True
+
 Support
 -------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/doc/index.rst 
new/proteus-4.6.5/doc/index.rst
--- old/proteus-4.2.4/doc/index.rst     1970-01-01 01:00:00.000000000 +0100
+++ new/proteus-4.6.5/doc/index.rst     2018-11-17 15:31:43.000000000 +0100
@@ -0,0 +1 @@
+.. include:: ../README
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus/__init__.py 
new/proteus-4.6.5/proteus/__init__.py
--- old/proteus-4.2.4/proteus/__init__.py       2018-07-05 11:53:55.000000000 
+0200
+++ new/proteus-4.6.5/proteus/__init__.py       2018-08-20 22:55:18.000000000 
+0200
@@ -3,8 +3,6 @@
 '''
 A library to access Tryton's models like a client.
 '''
-__version__ = "4.2.4"
-__all__ = ['Model', 'Wizard', 'Report']
 import sys
 try:
     import cdecimal
@@ -21,6 +19,9 @@
 
 import proteus.config
 
+__version__ = "4.6.5"
+__all__ = ['Model', 'Wizard', 'Report']
+
 _MODELS = threading.local()
 
 
@@ -619,6 +620,36 @@
         with Relation._config.set_context(self._get_context()):
             return Relation.find(new_domain, offset, limit, order)
 
+    def set_sequence(self, field='sequence'):
+        changed = False
+        prev = None
+        for record in self:
+            if prev:
+                index = getattr(prev, field)
+            else:
+                index = None
+            update = False
+            value = getattr(record, field)
+            if value is None:
+                if index:
+                    update = True
+                elif prev and record.id >= 0:
+                    update = record.id < prev.id
+            elif value == index:
+                if prev and record.id >= 0:
+                    update = record.id < prev.id
+            elif value <= (index or 0):
+                update = True
+            if update:
+                if index is None:
+                    index = 0
+                index += 1
+                setattr(record, field, index)
+                changed = record
+            prev = record
+        if changed:
+            self._changed()
+
 
 class Model(object):
     'Model class for Tryton records'
@@ -712,6 +743,9 @@
     def __hash__(self):
         return hash(self.__class__.__name__) ^ hash(self.id)
 
+    def __int__(self):
+        return self.id
+
     @property
     def id(self):
         'The unique ID'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus/config.py 
new/proteus-4.6.5/proteus/config.py
--- old/proteus-4.2.4/proteus/config.py 2018-03-01 23:00:35.000000000 +0100
+++ new/proteus-4.6.5/proteus/config.py 2018-08-20 22:55:18.000000000 +0200
@@ -152,8 +152,7 @@
         self._object = model
         self._config = config
 
-    def __call__(self, *args):
-        from trytond.cache import Cache
+    def __call__(self, *args, **kwargs):
         from trytond.rpc import RPC
         from trytond.tools import is_instance_method
         from trytond.transaction import Transaction
@@ -167,9 +166,8 @@
 
         with Transaction().start(self._config.database_name,
                 self._config.user, readonly=rpc.readonly) as transaction:
-            Cache.clean(self._config.database_name)
             args, kwargs, transaction.context, transaction.timestamp = \
-                rpc.convert(self._object, *args)
+                rpc.convert(self._object, *args, **kwargs)
             meth = getattr(self._object, self._name)
             if (rpc.instantiate is None
                     or not is_instance_method(self._object, self._name)):
@@ -184,7 +182,6 @@
                         for i in inst]
             if not rpc.readonly:
                 transaction.commit()
-            Cache.resets(self._config.database_name)
         return result
 
 
@@ -216,7 +213,6 @@
         from trytond.config import config
         config.update_etc(config_file)
         from trytond.pool import Pool
-        from trytond.cache import Cache
         from trytond.transaction import Transaction
         self.database = database
         database_name = None
@@ -234,7 +230,6 @@
         self.pool.init()
 
         with Transaction().start(self.database_name, 0) as transaction:
-            Cache.clean(database_name)
             User = self.pool.get('res.user')
             transaction.context = self.context
             self.user = User.search([
@@ -242,7 +237,6 @@
                 ], limit=1)[0].id
             with transaction.set_user(self.user):
                 self._context = User.get_preferences(context_only=True)
-            Cache.resets(database_name)
     __init__.__doc__ = object.__init__.__doc__
 
     def __repr__(self):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus/pyson.py 
new/proteus-4.6.5/proteus/pyson.py
--- old/proteus-4.2.4/proteus/pyson.py  2018-05-07 23:38:40.000000000 +0200
+++ new/proteus-4.6.5/proteus/pyson.py  2018-08-20 22:55:18.000000000 +0200
@@ -1,12 +1,11 @@
 # This file is part of Tryton.  The COPYRIGHT file at the top level of
 # this repository contains the full copyright notices and license terms.
-import datetime
 import json
+import datetime
+from dateutil.relativedelta import relativedelta
 from decimal import Decimal
 from functools import reduce, wraps
 
-from dateutil.relativedelta import relativedelta
-
 __all__ = ['PYSONEncoder', 'PYSONDecoder', 'Eval', 'Not', 'Bool', 'And', 'Or',
     'Equal', 'Greater', 'Less', 'If', 'Get', 'In', 'Date', 'DateTime', 'Len']
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus/tests/test_config.py 
new/proteus-4.6.5/proteus/tests/test_config.py
--- old/proteus-4.2.4/proteus/tests/test_config.py      2016-11-28 
18:43:52.000000000 +0100
+++ new/proteus-4.6.5/proteus/tests/test_config.py      2018-08-20 
22:55:18.000000000 +0200
@@ -13,6 +13,13 @@
                 config.context)[0]
         self.assert_(user_id == config.user)
 
+    def test_proxy_keyword(self):
+        config = proteus.config.get_config()
+        user_proxy = config.get_proxy('res.user')
+        user_id, = user_proxy.search(
+            [('login', '=', 'admin')], limit=1, context=config.context)
+        self.assert_(user_id == config.user)
+
     def test_proxy_methods(self):
         config = proteus.config.get_config()
         self.assert_('search' in config.get_proxy_methods('res.user'))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus/tests/test_model.py 
new/proteus-4.6.5/proteus/tests/test_model.py
--- old/proteus-4.2.4/proteus/tests/test_model.py       2016-11-28 
18:43:52.000000000 +0100
+++ new/proteus-4.6.5/proteus/tests/test_model.py       2018-08-20 
22:55:18.000000000 +0200
@@ -19,6 +19,11 @@
         User = Model.get('res.user')
         self.assert_(len(User.search([('login', '=', 'admin')], {})))
 
+    def test_int(self):
+        User = Model.get('res.user')
+        admin = User.find([('login', '=', 'admin')])[0]
+        self.assertEqual(int(admin), admin.id)
+
     def test_find(self):
         User = Model.get('res.user')
         admin = User.find([('login', '=', 'admin')])[0]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus.egg-info/PKG-INFO 
new/proteus-4.6.5/proteus.egg-info/PKG-INFO
--- old/proteus-4.2.4/proteus.egg-info/PKG-INFO 2018-07-05 11:53:57.000000000 
+0200
+++ new/proteus-4.6.5/proteus.egg-info/PKG-INFO 2018-12-03 00:47:53.000000000 
+0100
@@ -1,12 +1,12 @@
 Metadata-Version: 1.1
 Name: proteus
-Version: 4.2.4
+Version: 4.6.5
 Summary: Library to access Tryton server as a client
 Home-page: http://www.tryton.org/
 Author: Tryton
 Author-email: [email protected]
 License: LGPL-3
-Download-URL: http://downloads.tryton.org/4.2/
+Download-URL: http://downloads.tryton.org/4.6/
 Description-Content-Type: UNKNOWN
 Description: proteus
         =======
@@ -116,6 +116,28 @@
         
             >>> type_, data, print_, name = label.execute([party], {})
         
+        Sorting addresses and register order
+        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+        
+        Addresses are ordered by sequence which means they can be stored 
following a
+        specific order. The `set_sequence` method stores the current order.
+        
+            >>> address = party.addresses.new(zip='69')
+            >>> party.save()
+            >>> address = party.addresses.new(zip='23')
+            >>> party.save()
+        
+        Now changing the order.
+        
+            >>> reversed_addresses = list(reversed(party.addresses))
+            >>> while party.addresses:
+            ...     _ = party.addresses.pop()
+            >>> party.addresses.extend(reversed_addresses)
+            >>> party.addresses.set_sequence()
+            >>> party.save()
+            >>> party.addresses == reversed_addresses
+            True
+        
         Support
         -------
         
@@ -153,9 +175,9 @@
 Classifier: License :: OSI Approved :: GNU Library or Lesser General Public 
License (LGPL)
 Classifier: Operating System :: OS Independent
 Classifier: Programming Language :: Python :: 2.7
-Classifier: Programming Language :: Python :: 3.3
 Classifier: Programming Language :: Python :: 3.4
 Classifier: Programming Language :: Python :: 3.5
+Classifier: Programming Language :: Python :: 3.6
 Classifier: Programming Language :: Python :: Implementation :: CPython
 Classifier: Programming Language :: Python :: Implementation :: PyPy
 Classifier: Topic :: Office/Business
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus.egg-info/SOURCES.txt 
new/proteus-4.6.5/proteus.egg-info/SOURCES.txt
--- old/proteus-4.2.4/proteus.egg-info/SOURCES.txt      2018-07-05 
11:53:58.000000000 +0200
+++ new/proteus-4.6.5/proteus.egg-info/SOURCES.txt      2018-12-03 
00:47:54.000000000 +0100
@@ -8,6 +8,7 @@
 README
 setup.py
 tox.ini
+doc/index.rst
 proteus/__init__.py
 proteus/config.py
 proteus/pyson.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/proteus.egg-info/requires.txt 
new/proteus-4.6.5/proteus.egg-info/requires.txt
--- old/proteus-4.2.4/proteus.egg-info/requires.txt     2018-07-05 
11:53:57.000000000 +0200
+++ new/proteus-4.6.5/proteus.egg-info/requires.txt     2018-12-03 
00:47:53.000000000 +0100
@@ -4,4 +4,4 @@
 cdecimal
 
 [trytond]
-trytond<4.3,>=4.2
+trytond<4.7,>=4.6
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/setup.py new/proteus-4.6.5/setup.py
--- old/proteus-4.2.4/setup.py  2016-11-28 18:43:52.000000000 +0100
+++ new/proteus-4.6.5/setup.py  2018-08-20 22:55:18.000000000 +0200
@@ -66,9 +66,9 @@
         'GNU Library or Lesser General Public License (LGPL)',
         'Operating System :: OS Independent',
         'Programming Language :: Python :: 2.7',
-        'Programming Language :: Python :: 3.3',
         'Programming Language :: Python :: 3.4',
         'Programming Language :: Python :: 3.5',
+        'Programming Language :: Python :: 3.6',
         'Programming Language :: Python :: Implementation :: CPython',
         'Programming Language :: Python :: Implementation :: PyPy',
         'Topic :: Office/Business',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/proteus-4.2.4/tox.ini new/proteus-4.6.5/tox.ini
--- old/proteus-4.2.4/tox.ini   2016-11-28 18:43:52.000000000 +0100
+++ new/proteus-4.6.5/tox.ini   2018-08-20 22:55:18.000000000 +0200
@@ -1,5 +1,5 @@
 [tox]
-envlist = py27,py33,py34,py35,pypy
+envlist = py27,py34,py35,py36,pypy
 
 [testenv]
 commands = {envpython} setup.py test


Reply via email to