IRC logs of #tryton for Thursday, 2014-11-27 #tryton log beginning Thu Nov 27 00:00:01 CET 2014
-!- hiaselhans( has joined #tryton00:01
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton00:36
-!- digitalsatori(~Thunderbi@ has joined #tryton00:45
-!- digitalsatori(~Thunderbi@ has joined #tryton00:49
-!- leio(~leio@gentoo/developer/leio) has joined #tryton00:56
-!- digitalsatori1(~Thunderbi@ has joined #tryton00:59
-!- digitalsatori(~Thunderbi@ has joined #tryton01:23
-!- udono( has joined #tryton01:40
-!- TheCowboy( has joined #tryton03:44
-!- Alex_E1( has joined #tryton05:05
-!- sunny_dealmeida(~quassel@ has joined #tryton05:35
-!- yangoon1( has joined #tryton06:01
-!- digitalsatori(~Thunderbi@ has joined #tryton06:25
-!- digitalsatori1(~Thunderbi@ has joined #tryton06:36
-!- frispete_( has joined #tryton06:40
-!- horli( has joined #tryton07:17
-!- horli( has left #tryton07:17
-!- pjstevns(~Thunderbi@2001:981:7170:1:fd99:353:2a48:60b2) has joined #tryton07:53
-!- prksh(~prksh@ has joined #tryton07:59
-!- horli( has joined #tryton08:03
-!- horli( has left #tryton08:03
-!- vak0160(~kvirc@ has joined #tryton08:07
-!- vak0160(~kvirc@ has joined #tryton08:08
-!- vak0160(~kvirc@ has left #tryton08:12
-!- pobsteta( has joined #tryton08:12
-!- Timitos( has joined #tryton08:16
-!- horli( has joined #tryton08:55
-!- jeancavallo( has joined #tryton09:09
-!- corro(~corro@ has joined #tryton09:29
-!- LordVan(~LordVan@gentoo/developer/LordVan) has joined #tryton09:29
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton09:30
-!- digitalsatori(~Thunderbi@ has joined #tryton09:33
-!- bechamel( has joined #tryton09:35
-!- digitalsatori(~Thunderbi@ has joined #tryton09:42
-!- digitalsatori(~Thunderbi@ has joined #tryton09:49
-!- digitalsatori(~Thunderbi@ has joined #tryton10:17
-!- horli(~gregor@ has joined #tryton10:41
-!- horli(~gregor@ has left #tryton10:45
pobstetaHi all. I want to update a many2many attribute with an on_change_with function but this code don't update the attribute protection ?10:53
cedkpobsteta: you mean the value11:00
cedkpobsteta: you must return a list of ids11:01
cedkpobsteta: by the way, why usgin SQL query when you can just use the ORM11:01
cedkpobsteta: oh I see there is a special operator11:06
pobstetacedk: a list like this : {1, 2} or [1 , 2] ?11:07
cedkpobsteta: list = []11:09
-!- frispete( has joined #tryton11:14
pobstetahow can i use the ORM ?11:15
cedkpobsteta: not with custom operator for now11:17
pobstetaok it work, thanks for all !11:20
-!- mar( has joined #tryton11:24
mari coudn't find guidelines for creating a patch so
cedkPilou: the quick start is still way too long11:29
-!- nicoe( has joined #tryton11:33
marhow do i get a password in codereview?11:34
cedkmar: it uses google account11:34
-!- udono( has joined #tryton11:37
Piloucedk: which steps are unnecessary ?11:37
cedkPilou: i'm working on a patch11:37
cedkPilou: I think I will remove a lot11:37
-!- VaticanCameos(~pritishc@ has joined #tryton11:38
cedkPilou: I give up, there are way too much of blabla11:39
cedkPilou: I understand now why people tells it is too complicate to contribute11:39
cedkto contribute it is 4 lines11:39
marprobably missed ":" :/11:40
cedkthis howto tunrs the contribution process into a bureaucratic stuff11:43
PilouMy idea was to list all the steps which could permit a contributor to have his contribution approved.11:44
marcedk, is it good enough?11:44
maror do I still miss something?11:44
cedkPilou: that's a dream11:45
Piloucould you elaborate ?11:45
-!- kstenger(~karla@ has joined #tryton11:45
cedkPilou: a contribution should be just submiting a patch11:45
Piloubut it's not11:45
cedkPilou: when i conrtibute to cPython, I don't care at all about all the internal stuffs/rules11:46
PilouI follow the python quick start ( and added the codereview parts11:46
cedkPilou: I just submit a patch11:46
cedkmar: what?11:46
Timitoscedk: there are so many points where you can fail. if somebody wants to do his first contribution it is not really only 4 line11:47
mardo I miss something in this contribution11:47
cedkTimitos: it should not11:48
cedkTimitos: improving workflow is not about adding documentation, it is about reducing the possible failure11:48
cedkmar: I don't think11:48
PilouTimitos: indeed11:49
Piloucedk: i only wrote documentation for the current workflow11:50
Timitoscedk: at least you need to create a google account if you dont have one before you can start with 4 lines and you have to create a account on the bug tracker11:50
Piloucedk: improvements of the workflow should be discussed in the ML11:50
cedkIf I have to read 200 lines of doc, to submit a patch than I will fail at reading11:50
yangoonPilou: +111:50
cedkTimitos: account to bug tracker is not required11:50
margithub is the way :)11:51
cedkPilou: except people reading it, just give up because it is too complicate to read11:51
cedkmar: the workflow is easier than github, 4 lines11:51
Pilou(soon google account will not be required)11:52
cedkmar: and I count running vi and cd11:52
marit took me 30 minutes to do those 4 commands11:53
mari would have done it on github in 5 minutes :)11:53
cedkmar: I count 13min on irc11:54
cedkmar: any way, github is not the discussion, it is a privative platform and we are a freesoftware11:55
Timitosmar: donĀ“t forget, that you are already used to the contribution process on github. you need to think of your first time as you had to create a pull request on github11:55
cedkPilou: FYI, now the process doesn't require anymore to attach the patch to the bug tracker11:57
cedkI will work on a bot, that will add the review id to issue for each new review that has issuexxx in its comment11:58
-!- horli(~gregor@ has joined #tryton11:59
-!- horli(~gregor@ has left #tryton11:59
cedkmar: also you should now count how much time for the next one?12:00
rmuI contributed I think about 2-3 patches, and I didn't find it too hard to do it, after finding out about hgreview.12:01
rmuthings that were non-obvious to me: how to enter the bug tracker issue id into the hreview description, and that it was necessary to attach a patch to the bug after review was completed12:02
cedkrmu: I'm also working on it:
cedkrmu: and for the patch attachment, it is gone as now we (committers) can download the patch with all information ready to be imported in hg12:04
Piloucedk: how is handled the commit message ?12:04
-!- mariomop(~quassel@ has joined #tryton12:04
cedkPilou: the commit message is the review dsubject (with module name) and the review description12:05
cedkI also plan to add to hgreview a hook on commit to prefill the commit message with the review one12:05
cedkPilou: alos the review id is automaticaly appended to the patch12:06
cedkPilou: look at
-!- smarro(~sebastian@ has joined #tryton12:37
-!- ytz( has joined #tryton13:05
cedknicoe: I could not test:
cedknicoe: I have not access to the user13:30
cedknicoe: I also think it should a user on moretus with a email13:31
-!- frispete( has joined #tryton13:54
-!- vcardon( has joined #tryton13:59
-!- hiaselhans( has joined #tryton14:03
nicoecedk: indeed we should promote this test to something more official14:12
-!- pablovannini( has joined #tryton14:27
marcan this be a rounding error:
mari picked_quantities = 0.999999999 < move.quantity = 114:57
marand is it possible to have a race condition in assign_try method? I mean when two assignments happens concurrently?14:59
pokolimar:  stock_moves table is locked on assign_try15:09
marbut it's locked in exclusive mode15:12
marwhich means reads are still possible15:13
marso it doesn't block loading quantities which may be wrong15:15
marif another assign is happening at the same time?15:15
maram I right? :)15:23
pokolimar: i imagine that yes, you're right, but haven't tested it15:38
-!- hiaselhans( has joined #tryton15:44
marI have a situation where there are more products assigned than available15:47
pokolimar: what i can tell is that i can not see any reason to block all the stock table in ACCESS EXCLUSIVE mode15:51
marprobably quantity loading should be done with "FOR UPDATE"15:52
pokolimar: could you explain how you get to the situation where tehere are more products assigned than available?15:55
maropen two tryton windows, create two productions which uses same products15:55
marboth productions should have "many" moves15:56
marso that assignment doesn't happen imediately15:56
marand click assign button in both windows15:56
marresult = both production are fully assigned15:56
marexpected result: one production is not assigned (missing qty)15:57
marif running one by one I get expected result, running them concurrently I get both of them assigned ;)15:57
marfor best results "offending" move should probably be last16:00
pokolimar: understood16:01
pokolimar: main problem about "FOR UPDATE" is that python-sql doesn't support it16:02
marI believe it does16:02
marat least the current version16:04
pokolimar: ouch, i missed this line :)16:04
pokolimar: yes, you're right it supports it16:05
pokolimar: so go ahead and write a patch16:06
marI'm not sure about the correct way16:07
pokolimar: can help you on this (at least try)16:07
maradding .for_ here?16:09
pokolimar: first of all, i think you need some kind of flag to especify if it's for update or not16:09
pokolimar: forget it, not sure about it :)16:10
pokolimar: i think that you don't need to look on the union all, but only on the first two queries that are from move table16:10
rmumar: I would start writing a test-case/test-scenario that reproduces the error16:14
pokolirmu: not sure if possible because it's all about concurrency16:18
pokolimar: at least you can open an issue on the bug tracker :)16:18
rmumar: what database are you using?16:23
-!- pobsteta( has joined #tryton16:33
-!- prksh(~prksh@ has joined #tryton16:39
-!- horli(~gregor@ has joined #tryton16:40
-!- horli(~gregor@ has left #tryton16:40
pokolimar: will you try to provide a patch?16:44
marthis is related16:46
marpokoli, not until monday ;)16:46
cedkmar: I can not see how this can happen, assignation needs to update the table16:47
cedkmar: so lock IN EXCLUSIVE MODE should prevent that16:47
pokolicedk: I imagine that the first read is done without the assigned data, so the other transaction sees the starting values, and then it locks when trying to write the moves16:50
marreading quantities isn't blocking operation. 1. process1 locks in exclusive mode, 2. process2 locks in exclusive mode, 3. process1 reads quantities, 4. process2 reads quantities, 5. process1 assigns, releases lock, 6. process2 assigns, releases lock16:50
cedkmar: how 5 if 2 was done16:52
cedkand lock table in exclusive mode are mutualy exclusif16:54
cedkI think the culpitre is the change to repeatable read instead of serializable16:56
-!- TheCowboy( has joined #tryton16:59
rmuthis causes div by zero, interestingly, sale does it differently:
mari'll try to log all queries happening in order for the concurrency issue17:07
cedkmar: for me, it is clear what happens17:19
cedkmar: taking your numbers:17:19
cedk1, 3, 5, 2, 4, 617:20
cedkbut 4 and 6 are reading the values before the commit of 517:20
cedkbecause it uses the repeatable read17:20
-!- vcardon( has left #tryton17:42
-!- prksh(~prksh@ has joined #tryton17:45
-!- prksh(~prksh@ has joined #tryton18:00
-!- Telesight( has joined #tryton18:12
cedknicoe: I migrated reviewbot to his own user and created an account reviewbot@tryton.org18:38
cedknicoe: but I see it uses hgreview and so it request the password in stdin18:43
cedknicoe: of course the session is stored but for 30 days18:44
cedknicoe: how did you manage it?18:44
-!- sunny_dealmeida(~quassel@ has joined #tryton18:45
cedknicoe: OK I found, it is fixed with dev version of hgreview19:09
-!- prksh_(~prksh@ has joined #tryton20:02
-!- prksh(~prksh@ has joined #tryton20:12
-!- hiaselhans( has joined #tryton22:53
-!- horli( has joined #tryton23:01
-!- ytz( has joined #tryton23:36
-!- hiaselhans1( has joined #tryton23:53

Generated by 2.11.0 by Marius Gedminas - find it at!