El viernes, 3 de marzo de 2017, 5:14:35 (UTC-3), Sergi Almacellas Abellana
escribió:
>
> El 02/03/17 a les 23:32, Luis Deiana ha escrit:
> >
> >
> > El jueves, 2 de marzo de 2017, 5:54:01 (UTC-3), Sergi Almacellas
> > Abellana escribió:
> >
> > El 02/03/17 a les 01:49, Luis Deiana ha escrit:
> > > > Otros que si están instalados y no me molestaría
> > desinstalarlos.
> > > Esto es
> > > > posible?
> > >
> > > Si, desde el cliente. (o un truco via tryton-admin también se
> > podria)
> > >
> > >
> > > Desde el cliente 3.4.16 no me funciona la opcion de desinstalar.
> La
> > > opcion de tryton-admin podria probar, pero no encontre que es ni
> > como se
> > > usa.
> > Habia un bug en alguna version que hacia que no funcionarà lo de
> > desisntalar.
> >
> > Lo que raimon comenta, es marcar el módulo para desinstalar (desde
> la
> > base de datos o con el cliente de tryton) i luego ejecutar
> > trytond-admin
> > -d <base_datos> --all para aplicar las actualizaciones.
> >
> >
> > Hola.
> >
> > trytond-admin en tryton 3.4 al parecer no existe, entonces lo q hice
> fue:
>
> En la versión 3.4, debes el comando trytond es el equivalente a
> trytond-admin
> >
esto me dice cuando ejecuto:
luis@Tryton:~$ ~/tryton/trytond//bin/trytond -d SI_34 -all
usage: trytond [-h] [--version] [-c FILE] [--dev] [-v]
[-d DATABASE [DATABASE ...]] [-u MODULE [MODULE ...]] [--all]
[--pidfile FILE] [--logconf FILE] [--cron]
trytond: error: unrecognized arguments: -all
y si saco el argumento --all:
luis@Tryton:~$ ~/tryton/trytond//bin/trytond -d SI_34
[Fri Mar 03 13:30:29 2017] INFO:trytond.server:using default configuration
[Fri Mar 03 13:30:29 2017] INFO:trytond.server:initialising distributed
objects services
Traceback (most recent call last):
File "/home/luis/tryton/trytond//bin/trytond", line 80, in <module>
trytond.server.TrytonServer(options).run()
File "/home/luis/tryton/trytond/trytond/server.py", line 71, in run
self.start_servers()
File "/home/luis/tryton/trytond/trytond/server.py", line 178, in
start_servers
self.jsonrpcd.append(JSONRPCDaemon(hostname, port, ssl))
File "/home/luis/tryton/trytond/trytond/protocols/jsonrpc.py", line 382,
in __init__
self.server = server_class((interface, port), handler_class, 0)
File "/home/luis/tryton/trytond/trytond/protocols/jsonrpc.py", line 317,
in __init__
bind_and_activate)
File "/usr/lib/python2.7/SocketServer.py", line 419, in __init__
self.server_bind()
File "/home/luis/tryton/trytond/trytond/protocols/jsonrpc.py", line 346,
in server_bind
SimpleJSONRPCServer.server_bind(self)
File "/usr/lib/python2.7/SocketServer.py", line 430, in server_bind
self.socket.bind(self.server_address)
File "/usr/lib/python2.7/socket.py", line 224, in meth
return getattr(self._sock,name)(*args)
socket.error: [Errno 98] Address already in use
> > - copiar el archivo trytond-admin que esta desde la version 4.0 en la
> > version 3.4
> > - y ejecutar:
> >
> > luis@Tryton:~$ ./tryton/trytond/bin/trytond-admin -d SI_34 --all
> > Traceback (most recent call last):
> > File "./tryton/trytond/bin/trytond-admin", line 12, in <module>
> > import trytond.commandline as commandline
> > ImportError: No module named commandline
> >
> > como no funciono:
> >
> > - desde el cliente de tryton 3.4 marque el modulo para desinstalar
> > - hice un backup de la base desde el cliente 3.4 donde estaba el modulo
> > marcado
> > - intente levantar la base desde tryton 4.0 y me tira varios errores
> > como el siguente error:
> >
> > La orden era: ALTER TABLE ONLY stock_shipment_out
> > ADD CONSTRAINT stock_shipment_out_write_uid_fkey FOREIGN KEY
> > (write_uid) REFERENCES ...
> > PRECAUCIÓN: errores ignorados durante la recuperación: 2298
> > 9754 139785474922240 [2017-03-02 22:18:02,635] INFO werkzeug
> > 192.168.15.40 - - [02/Mar/2017 22:18:02] "POST /SI_40PRUEBA/ HTTP/1.1"
> 200 -
> >
>
> En la tabla stock_shipment_out tienes valores en la columna write_uid
> (Usuario de modificacion) que no existen en la table de usuarios.
>
> si ejecuto desde la version 4.0 no me reconoce la base:
luis@Tryton:~$ ~/tryton/trytond/bin/trytond-admin -d SI_40PRUEBA --all
Traceback (most recent call last):
File "/home/luis/tryton/trytond/bin/trytond-admin", line 21, in <module>
admin.run(options)
File "/home/luis/tryton/trytond/trytond/admin.py", line 23, in run
with Transaction().start(db_name, 0):
File "/home/luis/tryton/trytond/trytond/transaction.py", line 87, in start
database = Database(database_name).connect()
File "/home/luis/tryton/trytond/trytond/backend/sqlite/database.py", line
220, in connect
raise IOError('Database "%s" doesn\'t exist!' % db_filename)
IOError: Database "SI_40PRUEBA.sqlite" doesn't exist!
si le doy a tryton el archivo de configuracion para que me tome postgres:
luis@Tryton:~$ ~/tryton/trytond/bin/trytond-admin -c /etc/trytond.conf -d
SI_40PRUEBA --all
Traceback (most recent call last):
File "/home/luis/tryton/trytond/bin/trytond-admin", line 21, in <module>
admin.run(options)
File "/home/luis/tryton/trytond/trytond/admin.py", line 48, in run
Pool(db_name).init(update=options.update, lang=lang)
File "/home/luis/tryton/trytond/trytond/pool.py", line 155, in init
lang=lang)
File "/home/luis/tryton/trytond/trytond/modules/__init__.py", line 429,
in load_modules
_load_modules()
File "/home/luis/tryton/trytond/trytond/modules/__init__.py", line 398,
in _load_modules
load_module_graph(graph, pool, update, lang)
File "/home/luis/tryton/trytond/trytond/modules/__init__.py", line 237,
in load_module_graph
cls.__register__(module)
File "/home/luis/Tryton/tryton3.2/trytond/trytond/ir/module/module.py",
line 355, in __register__
AttributeError: 'Transaction' object has no attribute 'cursor'
luis@Tryton:~$
y si intento crear una base nueva en la consola del servidor me da el mismo
error:
3599 139768715691776 [2017-03-03 13:41:25,475] INFO werkzeug 192.168.15.40
- - [03/Mar/2017 13:41:25] "POST / HTTP/1.1" 200 -
3599 139768715691776 [2017-03-03 13:41:52,079] INFO
trytond.backend.postgresql.database connect to "SI_40PRUEBA3"
3599 139768715691776 [2017-03-03 13:41:52,086] INFO werkzeug 192.168.15.40
- - [03/Mar/2017 13:41:52] "POST /SI_40PRUEBA3/ HTTP/1.1" 200 -
3599 139768715691776 [2017-03-03 13:41:52,089] INFO
trytond.backend.postgresql.database connect to "template1"
3599 139768715691776 [2017-03-03 13:41:52,378] INFO
trytond.backend.postgresql.database connect to "SI_40PRUEBA3"
3599 139768715691776 [2017-03-03 13:41:52,452] INFO trytond.pool init pool
for "SI_40PRUEBA3"
3599 139768715691776 [2017-03-03 13:41:52,476] INFO trytond.modules ir
3599 139768715691776 [2017-03-03 13:41:52,476] INFO trytond.pool setup pool
for "SI_40PRUEBA3"
3599 139768715691776 [2017-03-03 13:41:52,628] INFO trytond.modules
ir:register ir.model.graph
3599 139768715691776 [2017-03-03 13:41:52,628] INFO trytond.modules
ir:register ir.model.workflow_graph
3599 139768715691776 [2017-03-03 13:41:52,628] INFO trytond.modules
ir:register ir.configuration
3599 139768715691776 [2017-03-03 13:41:52,662] INFO trytond.modules
ir:register ir.translation
3599 139768715691776 [2017-03-03 13:41:52,760] INFO trytond.modules
ir:register ir.translation.set.start
3599 139768715691776 [2017-03-03 13:41:52,763] INFO trytond.modules
ir:register ir.translation.set.succeed
3599 139768715691776 [2017-03-03 13:41:52,765] INFO trytond.modules
ir:register ir.translation.clean.start
3599 139768715691776 [2017-03-03 13:41:52,768] INFO trytond.modules
ir:register ir.translation.clean.succeed
3599 139768715691776 [2017-03-03 13:41:52,771] INFO trytond.modules
ir:register ir.translation.update.start
3599 139768715691776 [2017-03-03 13:41:52,774] INFO trytond.modules
ir:register ir.translation.export.start
3599 139768715691776 [2017-03-03 13:41:52,778] INFO trytond.modules
ir:register ir.translation.export.result
3599 139768715691776 [2017-03-03 13:41:52,781] INFO trytond.modules
ir:register ir.sequence.type
3599 139768715691776 [2017-03-03 13:41:52,833] INFO trytond.modules
ir:register ir.sequence
3599 139768715691776 [2017-03-03 13:41:52,937] INFO trytond.modules
ir:register ir.sequence.strict
3599 139768715691776 [2017-03-03 13:41:53,046] INFO trytond.modules
ir:register ir.ui.menu
3599 139768715691776 [2017-03-03 13:41:53,111] INFO trytond.modules
ir:register ir.ui.menu.favorite
3599 139768715691776 [2017-03-03 13:41:53,182] INFO trytond.modules
ir:register ir.ui.view
3599 139768715691776 [2017-03-03 13:41:53,288] INFO trytond.modules
ir:register ir.ui.view.show.start
3599 139768715691776 [2017-03-03 13:41:53,292] INFO trytond.modules
ir:register ir.ui.view_tree_width
3599 139768715691776 [2017-03-03 13:41:53,369] INFO trytond.modules
ir:register ir.ui.view_tree_state
3599 139768715691776 [2017-03-03 13:41:53,481] INFO trytond.modules
ir:register ir.ui.view_search
3599 139768715691776 [2017-03-03 13:41:53,553] INFO trytond.modules
ir:register ir.ui.icon
3599 139768715691776 [2017-03-03 13:41:53,615] INFO trytond.modules
ir:register ir.property
3599 139768715691776 [2017-03-03 13:41:53,686] INFO trytond.modules
ir:register ir.action
3599 139768715691776 [2017-03-03 13:41:53,762] INFO trytond.modules
ir:register ir.action.keyword
3599 139768715691776 [2017-03-03 13:41:53,856] INFO trytond.modules
ir:register ir.action.report
3599 139768715691776 [2017-03-03 13:41:53,978] INFO trytond.modules
ir:register ir.action.act_window
3599 139768715691776 [2017-03-03 13:41:54,102] INFO trytond.modules
ir:register ir.action.act_window.view
3599 139768715691776 [2017-03-03 13:41:54,221] INFO trytond.modules
ir:register ir.action.act_window.domain
3599 139768715691776 [2017-03-03 13:41:54,312] INFO trytond.modules
ir:register ir.action.wizard
3599 139768715691776 [2017-03-03 13:41:54,399] INFO trytond.modules
ir:register ir.action.url
3599 139768715691776 [2017-03-03 13:41:54,482] INFO trytond.modules
ir:register ir.model
3599 139768715691776 [2017-03-03 13:41:54,544] INFO trytond.modules
ir:register ir.model.field
3599 139768715691776 [2017-03-03 13:41:54,650] INFO trytond.modules
ir:register ir.model.access
3599 139768715691776 [2017-03-03 13:41:54,802] INFO trytond.modules
ir:register ir.model.field.access
3599 139768715691776 [2017-03-03 13:41:54,966] INFO trytond.modules
ir:register ir.model.button
3599 139768715691776 [2017-03-03 13:41:55,086] INFO trytond.modules
ir:register ir.model.data
3599 139768715691776 [2017-03-03 13:41:55,244] INFO trytond.modules
ir:register ir.model.print_model_graph.start
3599 139768715691776 [2017-03-03 13:41:55,249] INFO trytond.modules
ir:register ir.attachment
3599 139768715691776 [2017-03-03 13:41:55,399] INFO trytond.modules
ir:register ir.note
3599 139768715691776 [2017-03-03 13:41:55,467] INFO trytond.modules
ir:register ir.note.read
3599 139768715691776 [2017-03-03 13:41:55,629] INFO trytond.modules
ir:register ir.cron
3599 139768715691776 [2017-03-03 13:41:55,836] INFO trytond.modules
ir:register ir.lang
3599 139768715691776 [2017-03-03 13:41:55,926] INFO trytond.modules
ir:register ir.export
3599 139768715691776 [2017-03-03 13:41:55,995] INFO trytond.modules
ir:register ir.export.line
3599 139768715691776 [2017-03-03 13:41:56,095] INFO trytond.modules
ir:register ir.rule.group
3599 139768715691776 [2017-03-03 13:41:56,255] INFO trytond.modules
ir:register ir.rule
3599 139768715691776 [2017-03-03 13:41:56,403] INFO trytond.modules
ir:register ir.module.module
3599 139768715691776 [2017-03-03 13:41:56,478] WARNING
trytond.backend.postgresql.table unable to add 'unique (name)' constraint
on table ir_module_module !
If you want to have it, you should update the records and execute manually:
ALTER table "ir_module_module" ADD CONSTRAINT "ir_module_module_name_uniq"
unique (name)
3599 139768715691776 [2017-03-03 13:41:56,513] INFO trytond.modules
ir:register ir.module.module.dependency
3599 139768715691776 [2017-03-03 13:41:56,627] WARNING
trytond.backend.postgresql.table unable to add 'UNIQUE(name, module)'
constraint on table ir_module_module_dependency !
If you want to have it, you should update the records and execute manually:
ALTER table "ir_module_module_dependency" ADD CONSTRAINT
"ir_module_module_dependency_name_module_uniq" UNIQUE(name, module)
3599 139768715691776 [2017-03-03 13:41:56,661] INFO trytond.modules
ir:register ir.module.module.config_wizard.item
3599 139768715691776 [2017-03-03 13:41:56,670] ERROR
trytond.protocols.dispatcher CREATE DB: SI_40PRUEBA3 failed
Traceback (most recent call last):
File "/home/luis/tryton/trytond/trytond/protocols/dispatcher.py", line
262, in create
pool.init(update=['res', 'ir'], lang=[lang])
File "/home/luis/tryton/trytond/trytond/pool.py", line 155, in init
lang=lang)
File "/home/luis/tryton/trytond/trytond/modules/__init__.py", line 429,
in load_modules
_load_modules()
File "/home/luis/tryton/trytond/trytond/modules/__init__.py", line 398,
in _load_modules
load_module_graph(graph, pool, update, lang)
File "/home/luis/tryton/trytond/trytond/modules/__init__.py", line 237,
in load_module_graph
cls.__register__(module)
File "/home/luis/Tryton/tryton3.2/trytond/trytond/ir/module/module.py",
line 355, in __register__
AttributeError: 'Transaction' object has no attribute 'cursor'
3599 139768715691776 [2017-03-03 13:41:56,671] INFO werkzeug 192.168.15.40
- - [03/Mar/2017 13:41:56] "POST /SI_40PRUEBA3/ HTTP/1.1" 200 -
Graciassss
>
> > no se cual es la manera correcta pero ninguna me dio funciono ;(
>
> Deberias corregir los datos de tu base de datos. De todos modos, esto
> són solo avisos, por lo que podrás seguir trabajando correctamente.
> >
> > Saludos.
> >
> >
> > Saludos,
> >
> > --
> > Sergi Almacellas Abellana
> > www.koolpi.com <http://www.koolpi.com>
> > Twitter: @pokoli_srk
> >
>
>
> --
> Sergi Almacellas Abellana
> www.koolpi.com
> Twitter: @pokoli_srk
>