I've got a error when I tried to get a boleto

Bug #1301121 reported by Rafael Reuber
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Proge OpenERP Addons
New
Undecided
Unassigned

Bug Description

I'm getting a error when I do try to generate a boleto from a invoice.

Steps to reproduce the error:
The user goes on Sales > Sales Order and select a Invoice with a status "Sales Order" ;
The user clicks on View Invoice Button;
The system shows the Invoice;
The user goes on More button and cliks on Gerar Boleto;
 - The system show Gerar Boleto wizard;
 - The user select a bank from the list and press Gerar Boleto Button;

The system show a error message below:

2014-04-02 02:43:10,304 15600 ERROR localizacao openerp.netsvc: The barcode must have 44 caracteres, found 45
Traceback (most recent call last):
  File "/opt/openerp_loc/server/openerp/netsvc.py", line 292, in dispatch_rpc
    result = ExportService.getService(service_name).dispatch(method, params)
  File "/opt/openerp_loc/server/openerp/service/web_services.py", line 626, in dispatch
    res = fn(db, uid, *params)
  File "/opt/openerp_loc/server/openerp/osv/osv.py", line 190, in execute_kw
    return self.execute(db, uid, obj, method, *args, **kw or {})
  File "/opt/openerp_loc/server/openerp/osv/osv.py", line 132, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/opt/openerp_loc/server/openerp/osv/osv.py", line 199, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/opt/openerp_loc/server/openerp/osv/osv.py", line 187, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/opt/openerp_loc/localizacao_br_addons/boleto/wizard/boleto_create.py", line 155, in create_boleto
    boleto_file = self.gen_boleto(cr, uid, ids, boleto_ids, context)
  File "/opt/openerp_loc/localizacao_br_addons/boleto/wizard/boleto_create.py", line 197, in gen_boleto
    boleto_pdf.drawBoleto(boleto)
  File "/usr/local/lib/python2.7/dist-packages/pyboleto/pdf.py", line 815, in drawBoleto
    d = self._drawReciboCaixa(boletoDados, x, y)
  File "/usr/local/lib/python2.7/dist-packages/pyboleto/pdf.py", line 751, in _drawReciboCaixa
    boletoDados.linha_digitavel
  File "/usr/local/lib/python2.7/dist-packages/pyboleto/data.py", line 422, in linha_digitavel
    linha = self.barcode
  File "/usr/local/lib/python2.7/dist-packages/pyboleto/data.py", line 186, in barcode
    'The barcode must have 44 caracteres, found %d' % len(num))
BoletoException: The barcode must have 44 caracteres, found 45

Revision history for this message
Rafael Reuber (rafaelreuber-h) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.