Welcome!

This community is for professionals and enthusiasts of our products and services. Share and discuss the best content and new marketing ideas, build your professional profile and become a better marketer together.

0

Instalação Odoo v10 - Localização Brasil Trustcode

By
Thiago Macêdo
on 12/11/16 20:15 3.762 visualizações

Após fazer toda a instalação do sistema e dos módulos da localização brasileira, notei que um módulo não está instalando e reportando erro.  O módulo  Brazilian - Accounting (l10n_br) - Ele não é mais necessário? Pois todos os módulos foram instalados normalmente sem solicitarem ele com dependência.

Segue erro relatado após tentar instalar o módulo:


Odoo Server Error

Traceback (most recent call last):
  File "/odoo/odoo-server/odoo/http.py", line 638, in _handle_exception    return super(JsonRequest, self)._handle_exception(exception)  File "/odoo/odoo-server/odoo/http.py", line 675, in dispatch    result = self._call_function(**self.params)  File "/odoo/odoo-server/odoo/http.py", line 331, in _call_function    return checked_call(self.db, *args, **kwargs)  File "/odoo/odoo-server/odoo/service/model.py", line 119, in wrapper    return f(dbname, *args, **kwargs)  File "/odoo/odoo-server/odoo/http.py", line 324, in checked_call    result = self.endpoint(*a, **kw)  File "/odoo/odoo-server/odoo/http.py", line 933, in __call__    return self.method(*args, **kw)  File "/odoo/odoo-server/odoo/http.py", line 504, in response_wrap    response = f(*args, **kw)  File "/odoo/odoo-server/addons/web/controllers/main.py", line 866, in call_button    action = self._call_kw(model, method, args, {})  File "/odoo/odoo-server/addons/web/controllers/main.py", line 854, in _call_kw    return call_kw(request.env[model], method, args, kwargs)  File "/odoo/odoo-server/odoo/api.py", line 681, in call_kw    return call_kw_multi(method, model, args, kwargs)  File "/odoo/odoo-server/odoo/api.py", line 672, in call_kw_multi    result = method(recs, *args, **kwargs)  File "/odoo/odoo-server/odoo/addons/base/module/module.py", line 410, in button_immediate_install    return self._button_immediate_function(type(self).button_install)  File "/odoo/odoo-server/odoo/addons/base/module/module.py", line 484, in _button_immediate_function    modules.registry.Registry.new(self._cr.dbname, update_module=True)  File "/odoo/odoo-server/odoo/modules/registry.py", line 78, in new    odoo.modules.load_modules(registry._db, force_demo, status, update_module)  File "/odoo/odoo-server/odoo/modules/loading.py", line 337, in load_modules    loaded_modules, update_module)  File "/odoo/odoo-server/odoo/modules/loading.py", line 235, in load_marked_modules    loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks)  File "/odoo/odoo-server/odoo/modules/loading.py", line 156, in load_module_graph    _load_data(cr, module_name, idref, mode, kind='data')  File "/odoo/odoo-server/odoo/modules/loading.py", line 95, in _load_data    tools.convert_file(cr, module_name, filename, idref, mode, noupdate, kind, report)  File "/odoo/odoo-server/odoo/tools/convert.py", line 848, in convert_file    convert_xml_import(cr, module, fp, idref, mode, noupdate, report)  File "/odoo/odoo-server/odoo/tools/convert.py", line 918, in convert_xml_import    obj.parse(doc.getroot(), mode=mode)  File "/odoo/odoo-server/odoo/tools/convert.py", line 802, in parse    self._tags[rec.tag](rec, de, mode=mode)  File "/odoo/odoo-server/odoo/tools/convert.py", line 710, in _tag_record    id = self.env(context=rec_context)['ir.model.data']._update(rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode)  File "/odoo/odoo-server/odoo/addons/base/ir/ir_model.py", line 1180, in _update    record = record.create(values)  File "/odoo/odoo-server/odoo/models.py", line 3804, in create    record = self.browse(self._create(old_vals))  File "/odoo/odoo-server/odoo/models.py", line 3892, in _create    cr.execute(query, tuple(u[2] for u in updates if len(u) > 2))  File "/odoo/odoo-server/odoo/sql_db.py", line 141, in wrapper    return f(self, *args, **kwargs)  File "/odoo/odoo-server/odoo/sql_db.py", line 218, in execute    res = self._obj.execute(query, params)ParseError: "duplicate key value violates unique constraint "account_tax_template_name_company_uniq"DETAIL:  Key (name, company_id, type_tax_use)=(IPI Sa\xedda 3%, 1, sale) already exists.
" while parsing /odoo/odoo-server/addons/l10n_br/data/account_tax_template_data.xml:699, near<record id="tax_template_out_ipi3" model="account.tax.template">            <field name="description">IPI 3%</field>            <field name="name">IPI Sa&#237;da 3%</field>            <field name="amount">3</field>            <field name="type_tax_use">sale</field>            <field ref="account_template_201010301" name="account_id"/>            <field ref="account_template_101050502" name="refund_account_id"/>            <field eval="0" name="price_include"/>            <field eval="0" name="tax_discount"/>            <field ref="l10n_br_account_chart_template" name="chart_template_id"/>            <field name="tag_ids" eval="[(6,0,[ref('tag_br_24'), ref('tag_br_23')])]"/>           </record>


1

Danimar Ribeiro

--Danimar Ribeiro--
1098
| 1 0 1
Brasil
--Danimar Ribeiro--
Danimar Ribeiro
On 14/11/16 11:33

Não é mais necessário instalar este módulo, o módulo br_coa substitui o l10n_br.


  • Flag

Opa! Valeu Daminar! Imaginei isso, mais precisava ter certeza!

Grande Abraço!

Thiago Macêdo
em 15/11/16 01:17

0

Boa noite,

está funcionando quase tudo ótimo. Somente não consigo instalar http://xmlsoft.org/sources/python/libxml2-python-2.6.21.tar.gz

Tentei em ubuntu 14.04 e 16.04. Tem algum segredo?

Obrigado!

  • Flag

apt-get install libxml2-dev

Thiago Macêdo
em 17/11/16 00:34

infelizmente não. já pesquisei o dia inteiro e este foi a primeira ação que fiz. tentei tambem build-essential libssl-dev libffi-dev python-dev libxmlsec1-dev que encontrei. Tambem com python 2 e 3. no ubuntu 16.04 esta dando seguinte erro:

Processing ./libxml2-python-2.6.21.tar.gz

Building wheels for collected packages: libxml2-python

Running setup.py bdist_wheel for libxml2-python ... error

Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-pA_Erb-build/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmpu28uu4pip-wheel- --python-tag cp27:

/usr/lib/python2.7/distutils/dist.py:251: UserWarning: 'licence' distribution option is deprecated; use 'license'

warnings.warn(msg)

running bdist_wheel

running build

running build_py

creating build

creating build/lib.linux-x86_64-2.7

copying libxml2.py -> build/lib.linux-x86_64-2.7

copying drv_libxml2.py -> build/lib.linux-x86_64-2.7

copying libxslt.py -> build/lib.linux-x86_64-2.7

running build_ext

building 'libxml2mod' extension

creating build/temp.linux-x86_64-2.7

x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -D_REENTRANT=1 -DMERGED_MODULES=1 -I/usr/include/libxml2 -I/usr/include -I/usr/include/libxslt -I/usr/include/python2.7 -c libxml2-py.c -o build/temp.linux-x86_64-2.7/libxml2-py.o

x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -D_REENTRANT=1 -DMERGED_MODULES=1 -I/usr/include/libxml2 -I/usr/include -I/usr/include/libxslt -I/usr/include/python2.7 -c libxml.c -o build/temp.linux-x86_64-2.7/libxml.o

In file included from /usr/include/python2.7/Python.h:80:0,

from libxml.c:14:

libxml.c: In function ‘pythonStartElement’:

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:760:13: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:772:21: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

libxml.c: In function ‘libxml_xmlParserCtxtGetErrorHandler’:

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:1699:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:1701:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

libxml.c: In function ‘libxml_xmlTextReaderGetErrorHandler’:

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:2013:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:2015:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

libxml.c: In function ‘libxml_serializeNode’:

libxml.c:2807:28: error: dereferencing pointer to incomplete type ‘xmlBuf {aka struct _xmlBuf}’

len = buf->conv->use;

^

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

----------------------------------------

Failed building wheel for libxml2-python

Running setup.py clean for libxml2-python

Failed to build libxml2-python

Installing collected packages: libxml2-python

Running setup.py install for libxml2-python ... error

Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-pA_Erb-build/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-g9Xund-record/install-record.txt --single-version-externally-managed --compile:

/usr/lib/python2.7/distutils/dist.py:251: UserWarning: 'licence' distribution option is deprecated; use 'license'

warnings.warn(msg)

running install

running build

running build_py

creating build

creating build/lib.linux-x86_64-2.7

copying libxml2.py -> build/lib.linux-x86_64-2.7

copying drv_libxml2.py -> build/lib.linux-x86_64-2.7

copying libxslt.py -> build/lib.linux-x86_64-2.7

running build_ext

building 'libxml2mod' extension

creating build/temp.linux-x86_64-2.7

x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -D_REENTRANT=1 -DMERGED_MODULES=1 -I/usr/include/libxml2 -I/usr/include -I/usr/include/libxslt -I/usr/include/python2.7 -c libxml2-py.c -o build/temp.linux-x86_64-2.7/libxml2-py.o

x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -D_REENTRANT=1 -DMERGED_MODULES=1 -I/usr/include/libxml2 -I/usr/include -I/usr/include/libxslt -I/usr/include/python2.7 -c libxml.c -o build/temp.linux-x86_64-2.7/libxml.o

In file included from /usr/include/python2.7/Python.h:80:0,

from libxml.c:14:

libxml.c: In function ‘pythonStartElement’:

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:760:13: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:772:21: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

libxml.c: In function ‘libxml_xmlParserCtxtGetErrorHandler’:

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:1699:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:1701:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

libxml.c: In function ‘libxml_xmlTextReaderGetErrorHandler’:

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:2013:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

/usr/include/python2.7/object.h:824:38: warning: the comparison will always evaluate as ‘false’ for the address of ‘_Py_NoneStruct’ will never be NULL [-Waddress]

#define Py_XINCREF(op) do { if ((op) == NULL) ; else Py_INCREF(op); } while (0)

^

libxml.c:2015:2: note: in expansion of macro ‘Py_XINCREF’

Py_XINCREF(Py_None);

^

libxml.c: In function ‘libxml_serializeNode’:

libxml.c:2807:28: error: dereferencing pointer to incomplete type ‘xmlBuf {aka struct _xmlBuf}’

len = buf->conv->use;

^

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

----------------------------------------

Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-pA_Erb-build/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-g9Xund-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-pA_Erb-build/

Christian de Lamboy
em 17/11/16 09:35

Já tentou:

sudo apt-get install python-dev zlib1g-dev libxml2-dev libxslt-dev -y

?

Thiago Macêdo
em 17/11/16 14:26

infelizmente sim. Pode ser um problema que estou fazendo como root? Sou única pessoa com este problemo?

Christian de Lamboy
em 17/11/16 14:32

Não... tambem fiz o processo como root.

skype: thiago95macedo add aí

Thiago Macêdo
em 17/11/16 14:35

0

Bom dia thiago!
Estou começando a mexer com odoo agora! então não sei lhe responder se isso é um erro ou não.
Porém eu efetuei a instalação de todos os módulos do odoo e da trust sem problemas! Você esta instalando apenas os módulos que estão listados com a opção aplicativos? ou está limpando este filtro?
Este erro que está sendo apresentado é por causa dos dados padrões que já foram carregados por outro módulo ou então pela opção de carregar dados de demonstração! (como lhe disse ainda não domino muito bem o funcionamento do mesmo...)
Caso precise de ajuda ou queira trocar idéias sobre a instalação estou a disposição! assim aprenderemos juntos. hehe

  • Flag

Opa!!! E aí Alessandro, beleza?

Então... já estudo o Odoo a quase dois anos, minha dúvida era na realidade era mais na necessidade deste módulo na Localização Brasil!

Me add no skype aí, vamos sim trocar idéia e nos ajudar em relação ao Odoo!

skype: thiago95macedo

e-mail: thiago.macedo@adaxtechnology.com

Thiago Macêdo
em 15/11/16 01:21

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

Fique Informado

Sobre este fórum

Este fórum tem o intuito de debater sobre o Odoo no Brasil. Questõs relacionadas a tributação, melhores práticas. Leia Orientações

Ferramentas de Pergunta

4 seguidor (es)

Estatísticas

Perguntada: 12/11/16 20:15
Visto: 3762 vezes
Última atualização: 07/07/17 18:47