[tryton-debian] Bug#847436: Bug#847436: tryton-server: Upgrade does not work without tryton-modules-webdav
Mathias Behrle
mbehrle at debian.org
Thu Dec 8 15:32:19 UTC 2016
* Raphaël Hertzog: " [tryton-debian] Bug#847436: tryton-server: Upgrade does
not work without tryton-modules-webdav" (Thu, 08 Dec 2016 10:11:54 +0100):
> Source: tryton-server
> Version: 4.2.0-1
> Severity: important
>
> I'm upgrading a 3.8 instance towards 4.2 (on a jessie system) and in the
> process tryton-modules-webdav has not been installed.
>
> When I try to run the upgrade process I get this failure:
>
> $ sudo -u tryton trytond-admin -c /etc/tryton/trytond.conf --all -d tryton
> Traceback (most recent call last):
> File "/usr/bin/trytond-admin", line 21, in <module>
> admin.run(options)
> File "/usr/lib/python2.7/dist-packages/trytond/admin.py", line 53, in run
> pool.init(update=options.update, lang=list(lang))
> File "/usr/lib/python2.7/dist-packages/trytond/pool.py", line 155, in init
> lang=lang)
> File "/usr/lib/python2.7/dist-packages/trytond/modules/__init__.py", line
> 457, in load_modules _load_modules()
> File "/usr/lib/python2.7/dist-packages/trytond/modules/__init__.py", line
> 424, in _load_modules graph = create_graph(module_list)[0]
> File "/usr/lib/python2.7/dist-packages/trytond/modules/__init__.py", line
> 159, in create_graph info = get_module_info(module)
> File "/usr/lib/python2.7/dist-packages/trytond/modules/__init__.py", line
> 143, in get_module_info with tools.file_open(os.path.join(name,
> 'tryton.cfg')) as fp: File
> "/usr/lib/python2.7/dist-packages/trytond/tools/misc.py", line 76, in
> file_open raise IOError('File not found : %s ' % name) IOError: File not
> found : /usr/lib/python2.7/dist-packages/trytond/modules/webdav/tryton.cfg
The refactoring of the webdav module into a separate module was part of the
migration to 4.0. Wasn't that NEWS presented to you? I try to be very
considerate to put the very same date into NEWS and changelog and it is
identical for 4.0 and 4.2 AFAIS (and therefore should work).
An automatic installation of the webdav module into pre-existing databases that
had this module installed is far beyond the scope what I can do in Debian and
should be part of upstream code if at all.
I will try however to add more verbose information to the NEWS file.
> BTW, the NEWS.Debian should really instruct the user to run the upgrade
> with the rights of the tryton user (it suggests root since the command
> line starts with "#")
Agreed.
> and it should also include the
> "-c /etc/tryton/trytond.conf" otherwise you get other weird failures like
> this one: $ sudo -u tryton trytond-admin --all -d tryton
> Traceback (most recent call last):
> File "/usr/bin/trytond-admin", line 18, in <module>
> config.update_etc(options.configfile)
> File "/usr/lib/python2.7/dist-packages/trytond/config.py", line 73, in
> update_etc read_files = self.read(configfile)
> File "/usr/lib/python2.7/ConfigParser.py", line 302, in read
> fp = open(filename)
> TypeError: coercing to Unicode: need string or buffer, NoneType found
I would consider that exception a bug in trytond, it should simply start with
internal defaults when no configuration is defined.
Of course you are right, that it will be better to add the path to the
standard configuration file (despite the configuration could be in another place
due to some custom configuration of the system).
> And the "-v" flag would be welcome as well, otherwise you have the
> feeling that the upgrade gets stuck and you wonder what is going on.
Agreed.
Thanks for your comments and testing,
Mathias
--
Mathias Behrle
PGP/GnuPG key availabable from any keyserver, ID: 0xD6D09BE48405BBF6
AC29 7E5C 46B9 D0B6 1C71 7681 D6D0 9BE4 8405 BBF6
More information about the tryton-debian
mailing list