flask-tryton

Bug 7

classification
Title: Add support for Tryton >=5.2
Type: rfe Severity: normal
Components: Versions:
process
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: ced Nosy List: ced, pokoli, resteve, roundup-bot
Priority: normal Keywords: patch

Created on 2019-05-03 12:19 by resteve, last changed 2019-08-19 06:29 by roundup-bot.

Messages
msg11 Author: [hidden] (resteve) Date: 2019-05-03 12:19
Flask_tryton get error in v5.x (py3)

File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 2295, in wsgi_app
response = self.handle_exception(e)
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 1741, in handle_exception
reraise(exc_type, exc_value, tb)
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/_compat.py",
line 35, in reraise
raise value
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 2292, in wsgi_app
response = self.full_dispatch_request()
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 1815, in full_dispatch_request
rv = self.handle_user_exception(e)
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 1718, in handle_user_exception
reraise(exc_type, exc_value, tb)
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/_compat.py",
line 35, in reraise
raise value
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 1813, in full_dispatch_request
rv = self.dispatch_request()
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask/app.py",
line 1799, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File
"/home/resteve/.virtualenvs/tryton/lib/python3.5/site-packages/flask_tryton.py",
line 98, in wrapper
Cache.clean(database)
AttributeError: type object 'MemoryCache' has no attribute
'clean'

Also not found "resets":

Cache.resets(database)
msg12 Author: [hidden] (resteve) Date: 2019-05-03 13:15
Since v5.1. From issue https://bugs.tryton.org/issue7975

Review:

https://codereview.tryton.org/249371002/
msg13 Author: [hidden] (pokoli) Date: 2019-06-05 10:37
I've uploaded a fix on https://codereview.appspot.com/558820043
msg20 Author: [hidden] (ced) Date: 2019-07-18 08:15
I have updated the patch because Cache is managed by Transaction in 5.2.
Please test it.
msg21 Author: [hidden] (roundup-bot) Date: 2019-08-19 06:29
New changeset 9f49f708fad3 by C├ędric Krier in branch 'default':
Add support for 5.2 series
http://hg.b2ck.com/flask-tryton/rev/9f49f708fad3
History
Date User Action Args
2019-08-19 06:29:03roundup-botsetstatus: open -> closed
nosy: + roundup-bot
messages: + msg21
2019-07-18 08:15:58cedsetstatus: new -> open
nosy: + ced
messages: + msg20
priority: normal
assignee: ced
keywords: + patch
2019-06-05 10:37:23pokolisetnosy: + pokoli
messages: + msg13
2019-05-03 13:15:35restevesetmessages: + msg12
2019-05-03 13:03:12cedsettitle: MemoryCache' has no attribute 'clean' and 'resets' -> Add support for Tryton >=5.2
2019-05-03 13:02:43cedsetstatus: new
type: crash -> rfe
2019-05-03 12:19:43restevecreate