IRC logs of #tryton for Wednesday, 2014-04-30

chat.freenode.net #tryton log beginning Wed Apr 30 00:00:01 CEST 2014
-!- cjbarnes18(~craig@host109-157-158-41.range109-157.btcentralplus.com) has joined #tryton00:06
-!- digitalsatori(~Thunderbi@114.94.143.109) has joined #tryton04:12
-!- mar(~marius@v100.nfq.lt) has joined #tryton06:25
-!- sharoonthomas(~sharoonth@118.91.181.18) has joined #tryton06:27
-!- frispete_(~frispete@p54A93286.dip0.t-ipconnect.de) has joined #tryton06:41
-!- mar(~marius@v100.nfq.lt) has joined #tryton06:43
-!- yangoon(~mathiasb@p549F3889.dip0.t-ipconnect.de) has joined #tryton07:01
-!- smarro(~sebastian@190.105.93.196) has joined #tryton07:19
mari'm doing         invoice_line.quantity = Decimal('12.0')07:21
mar and I get ('UserError', (u"You try to read records that don't exist anymore.\n(Document type: currency.currency)", ''))07:21
marany ideas why?07:21
-!- pobsteta(~Thunderbi@pha75-11-82-236-85-232.fbx.proxad.net) has joined #tryton07:34
-!- bechamel(~Adium@62-197-96-189.teledisnet.be) has joined #tryton08:15
-!- bechamel(~Adium@62-197-96-189.teledisnet.be) has joined #tryton08:42
-!- nicoe(~nicoe@237.102-245-81.adsl-dyn.isp.belgacom.be) has joined #tryton09:03
marpokoli, are you there?09:04
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton09:09
pokolihi mar09:13
pokolimar: dificult to say with only this information09:14
pokolimar: which is the currency of the invoice you're modifing?09:15
marpokoli, i'm tryting to change invoice_line, just quantity, and I see that it tries to round amount09:17
martwo times, one on my invoice line, other on invoice_line without id09:17
-!- pobsteta(~Thunderbi@gut75-2-82-66-247-92.fbx.proxad.net) has joined #tryton09:18
marmethod     def on_change_with_amount(self):09:18
maris called two times, self value:09:18
maraccount.invoice.line,109:18
maraccount.invoice.line,None09:18
marhttp://hg.tryton.org/trytond/trytond/modules/account_invoice/file/782d5242ba05/invoice.py#l167509:20
pokolimar: the invoice is genereted by a sale or a purchase?09:20
maryes09:20
pokolimar: so the other line is the remaining quantity of the sale/purchase pending to invoice09:20
maroh, so it tries to create new invoice_line there?09:21
-!- jeancavallo(~giovanni@bob75-9-88-181-2-176.fbx.proxad.net) has joined #tryton09:21
pokolimar: yes09:21
mar(self.invoice.currency if self.invoice09:22
mar                else self.currency)09:22
marwhy does it use self.invoice.currency here then?09:22
pokolimar: do you have the invoice_standalone modules installed?09:23
marno09:23
maraccount.invoice,None09:23
mar== True for some reason09:23
pokolimar: If you look at http://hg.tryton.org/modules/sale/file/e30b58f6fd4a/invoice.py you can see that new lines are only created when the invoice is posted09:29
pokolimar: so I don't understand why it get's called on a on_change09:29
marwhere do you see posted?09:53
-!- sharoonthomas(~sharoonth@118.91.181.18) has joined #tryton09:55
pokolimar: here http://hg.tryton.org/modules/sale/file/e30b58f6fd4a/invoice.py#l9510:00
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton10:03
mari don't get it, where can I find method, which creates new account.invoice.line10:26
marfor purchase10:27
-!- xrg(~panos@ppp-2-84-137-19.home.otenet.gr) has joined #tryton10:28
-!- digitalsatori(~Thunderbi@114.94.143.109) has joined #tryton10:29
-!- meanmicio(~lfm@172.Red-83-38-121.dynamicIP.rima-tde.net) has joined #tryton10:31
-!- meanmicio(~lfm@fsf/member/meanmicio) has joined #tryton10:31
pokolimar: just print a traceback in the line where the error raises, to get the info about where is created the new line10:35
pokolimar: do you have custom modules?10:35
maryes I do, it may be the cause10:35
marthe other one that I can think of is context ;)10:36
pokolimar: so go for the traceback and you will know who creates the new line :)10:36
martrace is kindof useless10:36
marhttp://pastebin.com/ZYSJNJkx10:36
cedkmar: is your invoice line added to an invoice ?10:41
maryes cedk10:45
cedkmar: does the invoice has a currency?10:46
cedkmar: could you show your full proteus script?10:48
marhttp://pastebin.com/XdHaeT1310:48
marcrash is on         invoice_line.quantity = Decimal('12.')10:48
cedkmar: I don't understand, it is not a proteusscript10:49
mardo you call proteusscript the .rst?10:51
mari copypasted creation of objects I need into .py unittest10:51
cedkmar: which version?10:52
mar2.8.4 or 2.8.510:53
cedkmar: the problem is that you search the invoice line not comming from the invoice10:58
cedkmar: so proteus doesn't know anything about a parent and so does not send the invoice information10:58
cedkmar: and the module so thry to use the currency on the line10:59
cedkmar: with proteus, you have to follow the client workflow10:59
cedkmar: Model.get('account.invoice.line').find() can not be done on the client11:00
marif I get invoice, = purchase.invoices11:00
mar        invoice_line, = invoice.lines11:00
-!- digitalsatori(~Thunderbi@114.94.143.109) has joined #tryton11:00
marit works, thank you very much11:00
-!- frispete(~frispete@p54A93286.dip0.t-ipconnect.de) has joined #tryton11:19
-!- meanmicio(~lfm@172.Red-83-38-121.dynamicIP.rima-tde.net) has joined #tryton11:24
-!- meanmicio(~lfm@fsf/member/meanmicio) has joined #tryton11:24
-!- corro(~corro@46.22.23.85) has joined #tryton12:00
-!- sharoonthomas(~sharoonth@118.91.181.18) has joined #tryton12:46
-!- pobsteta(~Thunderbi@gut75-2-82-66-247-92.fbx.proxad.net) has joined #tryton13:35
-!- jeancavallo(~giovanni@bob75-9-88-181-2-176.fbx.proxad.net) has joined #tryton14:15
-!- pobsteta(~Thunderbi@gut75-2-82-66-247-92.fbx.proxad.net) has joined #tryton14:21
-!- sharoonthomas(~sharoonth@118.91.181.18) has joined #tryton14:23
corroin the spirit of issue3884 you could also remove the OrderedDict backport14:44
cedkcorro: patch is welcome14:44
corrocedk: new issue then?14:47
cedkcorro: yes14:49
-!- vcardon(~vcardon@LNeuilly-152-23-15-185.w193-252.abo.wanadoo.fr) has joined #tryton14:50
corrocedk: nevermind, it's already gone...14:52
corroACTION should think more before he talks14:53
-!- sharoonthomas(~sharoonth@118.91.181.18) has joined #tryton15:00
-!- LordVan(~LordVan@gentoo/developer/LordVan) has joined #tryton15:39
-!- mariomop(~quassel@host243.186-125-116.telecom.net.ar) has joined #tryton15:40
marcan someone explain me on_change and on_change_with usage?15:57
marI want to monitor one field change on model, and if it changes - do some actions on other models15:57
pokolimar: it's well explained on the docs16:21
pokolihttp://doc.tryton.org/3.2/trytond/doc/ref/models/fields.html?highlight=selection#trytond.model.fields.Field.on_change16:21
pokolimar: so what don't you understand?16:21
-!- smarro(~sebastian@190.105.93.196) has joined #tryton16:25
-!- naringas(~naringas@187.171.88.142) has joined #tryton16:26
-!- alisonken1lap3(~alisonken@18.18.ultimate-int.uia.net) has joined #tryton16:32
-!- digitalsatori(~Thunderbi@116.234.181.110) has joined #tryton16:34
-!- pablovannini(~pablo@host126.186-109-85.telecom.net.ar) has joined #tryton16:36
-!- udono(~udono@ip-176-199-172-92.unitymediagroup.de) has joined #tryton16:46
-!- naringas(~naringas@187.171.79.117) has joined #tryton16:51
-!- naringas(~naringas@187.171.79.117) has joined #tryton16:58
-!- pobsteta(~Thunderbi@37.160.57.218) has joined #tryton17:18
-!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton17:29
-!- digitalsatori(~Thunderbi@116.234.181.110) has joined #tryton17:33
pokolicedk: can I commit on www.tryton.org?18:28
-!- bechamel(~Adium@62-197-96-189.teledisnet.be) has joined #tryton18:35
-!- vcardon(~vcardon@LNeuilly-152-23-15-185.w193-252.abo.wanadoo.fr) has left #tryton18:44
-!- gremly(~gremly@190.85.36.58) has joined #tryton19:01
-!- LordVan(~lordvan@93.82.207.62) has joined #tryton20:37
-!- LordVan(~lordvan@gentoo/developer/LordVan) has joined #tryton20:37
-!- meanmicio(~lfm@172.Red-83-38-121.dynamicIP.rima-tde.net) has joined #tryton21:32
-!- meanmicio(~lfm@fsf/member/meanmicio) has joined #tryton21:32
-!- bechamel(~Adium@62-197-96-189.teledisnet.be) has joined #tryton22:15

Generated by irclog2html.py 2.11.0 by Marius Gedminas - find it at mg.pov.lt!