IRC logs of #tryton for Thursday, 2011-05-19 #tryton log beginning Thu May 19 00:00:02 CEST 2011
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton00:23
-!- lem0na(~lem0na@ has joined #tryton01:48
-!- rhubner(~rhubner@ has joined #tryton01:52
-!- rhubner(~rhubner@ has left #tryton01:53
-!- FWiesing( has left #tryton01:53
-!- blast_hardcheese( has joined #tryton02:30
-!- sharoon( has joined #tryton03:21
-!- gremly(~gremly@ has joined #tryton04:12
-!- effenber1( has joined #tryton04:15
-!- gremly(~gremly@ has joined #tryton05:05
-!- yangoon( has joined #tryton05:18
-!- ThePing(~phycho@ has joined #tryton06:14
-!- ThePing(~phycho@ has left #tryton06:14
-!- gremly(~gremly@ has joined #tryton06:42
-!- okko( has joined #tryton07:47
-!- trifon( has joined #tryton08:14
-!- pjstevns( has joined #tryton08:53
-!- sisalp( has joined #tryton09:02
-!- helmor(~helmor@ has joined #tryton09:17
-!- pjstevns( has joined #tryton09:18
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton09:29
-!- okko(~okko@ has joined #tryton09:40
sisalphello all, a discussion in French will start in about 15mn about account_fr in room tryton-fr10:06
-!- nicoe( has joined #tryton10:37
-!- nicoe( has joined #tryton10:41
-!- okko(~okko@ has joined #tryton10:49
-!- okko(~okko@ has joined #tryton10:56
-!- okko(~okko@ has joined #tryton11:01
-!- okko(~okko@ has joined #tryton11:18
-!- tshepang( has joined #tryton11:30
-!- trifon_( has joined #tryton11:58
-!- reichlich( has joined #tryton12:02
-!- bechamel( has joined #tryton12:28
-!- vladimirek( has joined #tryton12:46
-!- trifon__( has joined #tryton14:16
reichlichhi udono, id like to know what i have to do next for my GSOC project14:30
udonoreichlich: AFAIK we are in conception phase. cedk, bechamel, nicoe, sharoon?14:32
reichlichudono, is there a place where i can commit my code to talk about?14:33
udonoreichlich: yes, we use http://codereview.appspot.com14:34
udonoreichlich: for reviews14:34
udonoreichlich: sorry, wrong link...14:35
yangoonudono: there is also
reichlichudono, can i put there entire modules?14:41
udonoreichlich: yes, with upload.py14:42
udonoreichlich: see
reichlichudono, can handle new created nested repositories?14:50
udonoreichlich: I guess not.14:50
udonoreichlich: why nested?14:50
reichlichudono, id like to commit a module i created14:51
udonoreichlich: a trytond module?14:51
reichlichudono, yes14:51
reichlichudono, i implemented some synching stuff and would like to talk about it14:53
udonoreichlich: so just backup your module, then: Delete the .hg folder if exist, hg init, hg add <files-to-show>, upload.py14:53
udonoreichlich: backup your module first, because you will loose your revision history...14:54
udonoreichlich: maybe there is another way to push the module to codereview, but I know only this...14:55
reichlichudono, i cant generate a diff from my repo with my initial checkin14:56
-!- silverfox1971(~sysadmin0@ has joined #tryton14:56
udonoreichlich: I don't know how. Maybe it is possible...14:56
-!- silverfox1971(~sysadmin0@ has left #tryton14:57
udonoreichlich: AFAIK codereview only takes the last not committed diff to review...14:57
udonoreichlich: maybe the --rev option does what you want.15:01
udonoreichlich: see --help15:01
reichlichudono, the problem is theres no version to diff against15:02
udonoreichlich: so you did not use a cvs like hg for your module?15:03
reichlichudono, i got it work15:07
reichlichudono, i had to create a dummy file for an initial commit to patch against for the real data15:08
-!- sharoon( has left #tryton15:08
-!- sharoon( has joined #tryton15:08
reichlichudono, (i use mercurial)15:08
udonoreichlich: ok15:10
udonoreichlich: Best is to put the link for review here and on tryton-dev groups and ask the community for a review.15:11
-!- gremly(~gremly@ has joined #tryton15:18
yangoonreichlich I think it works with hg init and hg add all to have a suitable diff for codereview15:20
yangoonhg add all -> of course simply hg add15:21
reichlichyangoon, tried hg parent which returned nothing with no previously commit15:23
reichlichudono, i wrote some code for testing synching models with trytond servers:
reichlichudono, its just experimental but i can synch product.product with our production server with ~3000 products15:28
udonoreichlich commented15:37
reichlichudono, thanks15:37
reichlichudono, what do you think about the way of synching?15:37
udonoreichlich: Hard to say for the moment. It would be good to describe the general ideas and goals of the synchronizing mechanism. Upon this we can discuss the implementation more easy.15:39
-!- pjstevns( has joined #tryton15:41
udonoreichlich: But in general it looks promising.15:41
reichlichudono, is there a wiki for the GSOC students, where i can place my ideas?15:42
udonoreichlich: do you have a login to the google wiki we use?15:43
udonoreichlich: if not, just put cedk your gmail address15:44
nicoereichlich: you could also post your ideas on the blog you had to create for the GSOC15:47
reichlichcedk, can you give me a login for the google wiki?15:47
-!- pjstevns( has left #tryton15:51
cedkreichlich: what is you google account15:53
reichlichcedk, pokereichlich@t-online.de15:55
cedkreichlich: done15:57
reichlichcedk, thanks15:57
-!- dfamorato( has joined #tryton16:04
cedkreichlich: I think you can create a page in the blueprint sections16:05
cedkreichlich: try to not copy/paste content but use links16:05
cedkreichlich: try to keep stuffs maintainable and ordered16:06
reichlichcedk, did i something wrong?16:09
cedkreichlich: no just advertising16:13
-!- hoRn( has joined #tryton16:13
-!- zodman(~andres-va@foresight/developer/zodman) has joined #tryton16:23
-!- hoRn( has left #tryton16:37
-!- hoRn( has joined #tryton16:37
-!- okko(~okko@ has joined #tryton17:37
hoRnstrange behavior of vatnumber here: from python in shell i can check - from tryton it fails with 40418:11
cedkhoRn: the eu servers are not always reliable18:14
hoRncedk: but from shell it works18:15
hoRncedk: don't know ...18:15
cedkhoRn: hoRn are you sure it runs the same module version?18:24
udonohoRn: testing a German VAT Number is not possible sometime between 22:00 and 06:0018:24
hoRncedk, udono: still investigating ;)18:25
hoRnfrom shell i can do the import and than the check_vies-method18:26
hoRnfrom trytond it fails18:26
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton18:27
udonohoRn: are you sure both use vatnumber==0.9?18:28
udonohoRn: s.a.
yangoonhoRn: is trytond on the same machine?18:29
hoRnisn't the same - but will doublecheck my version of vatnumber18:29
hoRnyangoon: yes18:29
hoRnyangoon: <module 'vatnumber' from '/usr/lib/python2.5/site-packages/vatnumber-0.9-py2.5.egg/vatnumber/__init__.pyc'>18:36
hoRnseems good18:36
cedkhoRn: isn't there a proxy or firewall behind?18:41
hoRncedk: same machine - same python - or am I stupid ?18:42
udonohoRn: I have the same error with tryton.18:49
hoRnwhow - I got it18:50
hoRnis an suds issue: deleted the one in /usr/lib/pymodules/python2.5/18:52
hoRnand easy_installed again18:52
hoRnpip-easy_install-apt-issues again ;)18:56
hoRnudono: same in your environment?18:59
udonohoRn: which new suds version you use?19:03
yangoonhoRn: pip-easy_install-apt-issues what does it mean?19:03
yangoonFYI suds 0.4.1. is still in experimental in case you are using debian19:04
hoRnyangoon: i think apt is installing modules in pyshared - easy_install in site-packages - so sometimes its not clear which packages is finally used19:05
hoRnudono: using suds 0.419:05
yangoonhoRn: never install packages with apt _and_ easy_install19:06
udonohoRn: having the same version...19:06
reichlichwhat is the usage of the property field type?19:07
hoRnyangoon: yes - its true19:08
hoRnudono: what is the traceback?19:08
udonohoRn: :-) my vatnumber is old...19:09
hoRnudono: but don't use easy_install -U vatnumber - yangoon will insult you ;)19:11
hoRncan't explain the question of reichlich ....19:16
hoRnreichlich: first is similar to a Function-Field, but there is no need to define a getter or setter19:17
hoRnreichlich: the values are not stored in the table of your model - they are stored in the table ir.property19:19
reichlichand what is the advantage over an ordinary field?19:19
udonoreichlich: ;-)19:20
reichlichudono, thanks19:21
udonoreichlich: ... properties are defined in python and xml.19:25
udonoreichlich: ... they store their data in table ir_property.19:27
hoRnso the short answer is: use a Property, if this is a Value that can be different for distinct companies handled by one database?19:27
reichlichudono, its exactly what i was looking for.19:28
-!- sharoon( has left #tryton20:03
-!- sharoon( has joined #tryton20:03
-!- sharoon( has left #tryton20:23
-!- gremly(~gremly@ has joined #tryton20:29
-!- lem0na(~lem0na@ has joined #tryton20:45
-!- okko( has joined #tryton21:02
-!- sharoon( has joined #tryton21:12
sharooncedk: ping21:12
cedksharoon: pong21:13
cedksharoon: it is one time password?21:16
sharooncedk: yes21:16
sharooncedk: using yubico yubikey21:16
sharooncedk: works beautifully with tryton since we use sessions21:17
cedksharoon: why do you need 2 fields?21:18
sharooncedk: it is used in production, i cleaned it up and released with permission of customer21:18
sharooncedk: 2 fields - password & otp ? -> it is two factor authentication21:18
sharooncedk: so stealing of a key alone does not give access to the system21:18
cedksharoon: ok21:21
cedksharoon: did you try to use the plugins of the client?21:22
cedksharoon: it will be good to have it as a plugins21:22
sharooncedk: ok, i have never checked how the plugins work21:22
sharooncedk: any links or doc on it ?21:23
cedksharoon: no sorry :-(21:26
cedksharoon: I think you must do some mokey patching21:26
cedkACTION Lunch21:27
sharooncedk: will have a look21:27
-!- gremly(~gremly@ has joined #tryton22:06
-!- predatell(~werty@ has joined #tryton22:12
-!- okko( has joined #tryton22:38
-!- bechamel( has joined #tryton22:48
-!- hoRn( has left #tryton22:55
-!- rhubner(~rhubner@ has joined #tryton22:56
rhubnerHi sharoon!22:56
sharoonhi rhubner22:56
rhubnersharoon: I have some questions about the gsoc...22:57
sharoonrhubner: yes22:57
rhubnersharoon: I'm programming the editor out oh client...22:57
rhubnersharoon: Dou you think is possible development it already on the client and go directly to improving the final product?22:59
rhubnersharoon: Do you understand my question?22:59
sharoonrhubner: not really22:59
rhubnersharoon: for exemple... how I'll integrate the editor that I'm doing after in the client?23:00
rhubnersharoon: by the widget, right?23:01
sharoonrhubner: yes23:01
sharoonrhubner: did u go through the existing client code and how widgets het rendered ?23:01
rhubnersharoon: I don't know... is it possible?23:03
sharoonrhubner: ok, let's read some code.. sending you some links23:03
dfamoratobechamel: ping23:04
bechameldfamorato: pong23:05
rhubnersharoon: when there is the call of the plugin, rather than just add GtkTextView I add all the code editor created?23:05
bechameldfamorato: ced told me to check the irc log of yesterday23:05
dfamoratobechamel: hi... i discussed some design choices with cedk yesterday23:06
sharoonrhubner: yes23:06
dfamoratobechamel: mainly... we decided about using Real-Time indexing on sphinx23:06
bechameldfamorato: I'm gonna put online my latest work on the new search ui23:06
dfamoratobechamel: nice.... that will give me some direction on how to proceed23:06
rhubnersharoon: hummmm great!23:07
bechamelactually it doesn't change a lot of things for you23:07
rhubnersharoon: i'll go this way then!23:07
sharoonrhubner: ok, it will be easier to help if you have some code somewhere23:08
dfamoratobechamel: so, last time we discussed it's needed to create a tryton-driver which will pass all the necessary info for the sphinx indexer23:08
sharoonrhubner: BTW, this is the default widget code for text
dfamoratobechamel: that makes sphinx search platform independent23:08
dfamoratobechamel: i mean... database independant23:09
bechameldfamorato: yes23:09
rhubnersharoon: I'll finish the prototype and show you... And then you see if you can add it on the client23:09
sharoonrhubner: ok23:09
dfamoratobechamel: also... in order to support 16 languages on the stemming process.. we need to compile sphinx from source....23:10
bechameldfamorato: and I think an batch (non-realtime) is also needed, but it should be  trivial once the real-time implementation is done23:10
dfamoratobechamel:  I am not very familiar with packaging of tryton... by I don't see how to ship tryton + sphinx search enable easily23:10
bechameldfamorato: yes, but it's not really needed for developement. once you support 2 langage, you support an arbitrary number of them23:11
rhubnersharoon: can i change this code of TextBox, putting my code editor?23:11
rhubnersharoon: what is it easier?23:11
dfamoratodfamorato: ok... so using default sphinx packages will only give us English, Russion an Czech .. is that ok ?23:12
sharoonrhubner: i don't think that is required, because its the default widget. The Rich Text widget is only displayed if the xml overrides the widget to be rich text23:12
bechameldfamorato: It shouldn't be a problem, sphinx is already packaged on all major linux distro23:12
dfamoratobechamel: ok... so using default sphinx packages will only give us English, Russion an Czech .. is that ok ?23:12
bechameldfamorato: yes, at least for the beginning23:13
dfamoratobechamel: on the stemming process I mean..... lawfull = law.... friendly = friend and so on23:13
dfamoratodfamorato: ok... decided then23:13
bechameldfamorato: our job is not to test sphinx itself, we suppose it's working well with other langages23:14
rhubnersharoon: Ok, I understand that should keep the two versions ... But I can do my version from this?23:14
dfamoratobechamel: decided then... let's go for standard packages23:14
dfamoratobechamel: now.... which data should i consider to be indexed full-text ?23:14
bechameldfamorato: good question :)23:15
sharoonrhubner: of course all widgets are modelled very similar, and your nearest match is text23:15
bechameldfamorato: the simple is to first implement a basic API23:15
bechameldfamorato: iirc the idea was to push asynchronously23:16
dfamoratobechamel: you mean the driver which will retrieve the data from sphix and pass it to the indexer ?23:16
dfamoratobechamel: s/sphinx/tryton23:17
bechameldfamorato: yes23:17
rhubnersharoon: Ok.. then go from there, after I finish all the features of rich text editor....23:17
sharoonrhubner: yes23:18
bechameldfamorato: I don't know the sphinx API, is this something like: sphinx.push(bunch_of_text, language, db_id)23:18
rhubnersharoon: I'll make a merge later :) I think it works well ...23:18
sharoonrhubner: ok23:19
rhubnersharoon: one more question!23:19
dfamoratobechamel: in order to index data... we need to pass it to sphix indexer..23:19
sharoonrhubner: yes ?23:20
dfamoratobechamel: which accepts 3 kinds of data so far... MySql, Postgres and xml23:20
rhubnersharoon: the markup text...23:20
bechameldfamorato: and how to interact with it ? xml-rpc ?23:20
dfamoratobechamel: so I guess the driver I have to develop will have to export/push data to the indexer in the xml format23:20
bechameldfamorato: there are no existing python module t ease interaction with sphinx ?23:21
dfamoratobechamel: to interact with the search server, there is a python api... not very well documented but apparently good code23:21
rhubnersharoon: which will represent in italic, bold.... I'm thinking of doing this: [i]...[/i] and [b]...[/b]23:22
sharoonrhubner: i thin it is better to stick with some standard, cedk can you suggest23:22
bechameldfamorato: do you have an url ?23:22
dfamoratobechamel: yes... 1 min23:22
sharoonrhubner: the pythonic way of doing it might be ReST23:22
rhubnersharoon: can it be? or has to be something like html...23:22
-!- tshepang( has joined #tryton23:22
sharoonrhubner: can the widget not support HTML directly ? or atleast a subset of it ?23:23
sharoonrhubner: also there is
dfamoratobechamel: there are actually 4 components on the sphinx workflow23:26
rhubnersharoon: the pango markup language is good!23:27
dfamoratobechamel: the client program (which will be the tryton client) and will use the python api i just gave you. This interfaces with searchd program23:27
rhubnersharoon: so, i'll follow it23:27
sharoonrhubner: ok23:27
rhubnerThanks sharoon!23:28
dfamoratobechamel: 2-) the data source: I have to write a driver to "export" the data we want index from tryton and make it available to the indexer23:28
sharoonrhubner: good luck23:29
dfamoratobechamel: 3-) the indexer: fetches data from datasource and creates a full-text index of this data...23:29
dfamoratobechamel:  4-) searchd daemon... this will be listening from queries coming from the client(tryton client) and reply to the client with the matches and relevance23:30
bechameldfamorato: the tryton client must only interact with the trytond server23:31
bechameldfamorato: it's the job of the trytond server to query sphinx, and with the results answer the tryton client23:32
dfamoratobechamel: got it23:32
bechameldfamorato: and there is already a kind of mini framwork for what we need23:32
dfamoratodfamorato: can you please explain about this mini framework ?23:33
bechameldfamorato: take a look at the method search_rec_name in modules/party/party.py23:33
bechameldfamorato: around line 18423:33
dfamoratobechamel: ok23:33
dfamoratobechamel: ok... the search_rec_name method23:35
bechameldfamorato: when the tryton client does a search query with [('rec_name', '=', 'Doe')], the tryton server check if search_rec_name exist, and if yes use it23:35
bechameldfamorato:  and if not check if the attribute rec_name is set on the model23:35
bechameldfamorato: if yes it translate the query to [(<rec_name value>, '=', 'Doe')]23:36
bechameldfamorato: for exemple check stock/ line 1923:37
bechameldfamorato: this means [('rec_name', '=', 'Input zone')] will become [('location', '=', 'Input zone')]23:38
bechameldfamorato: and (finally) if _rec_name is absent, _rec_name is sipmliy defaulted to the field "name"23:39
bechameldfamorato: this is why most of models have a field called name23:39
bechameldfamorato: and this is where the new search gui will also help us, because by default it will call search_rec_name23:40
dfamoratobechamel: got it... so there is a mini framework which "translates"  some of the modules specific fields to the record name23:40
bechameldfamorato: exaclty23:41
dfamoratobechamel: and that is why we also need to make sphinx talk to the trytond directly because trytond is the only one that can "see"  this mapping23:42
bechameldfamorato: and conversely, the get_rec_name method tells how to display the current record (mostly for m2o fields)23:42
bechameldfamorato: yes23:42
bechameldfamorato: but I think it is not enough23:42
bechameldfamorato: or at least to simple23:43
bechameldfamorato: I think we need a way to tell, which model we want to index23:44
bechameldfamorato: maybe something with a _full_text_search = True on the model, that tell we want indexing23:45
bechameldfamorato: by default, we index the result of get_rec_name23:45
dfamoratobechamel: on each module, when saving the record you index the get_rec_name only.... and that is what you are saying it's not enought to be indexed ?23:46
bechameldfamorato: .. and finally a extra method that allow to override the values to index23:47
bechameldfamorato: yes, I'm searching an name for this extra method23:47
bechameldfamorato: get_index_content ?23:48
bechameldfamorato: get_rec_index ?23:48
dfamoratoget_rec_2index ?23:50
bechameldfamorato: maybe get_rec_excerpt, is better23:50
bechameldfamorato: but I'm not sure about the sphinx vocabulary23:51
dfamoratobechamel: and that method would be responsible for manually overriding/specifying which data we want to be full-text indexed, right ?23:52
bechameldfamorato: yes23:52
bechameldfamorato: does sphinx support some kind of key-value association ? lets say I want to index "first_name: john last_name: doe"23:53
bechameldfamorato: and when I search, I want just on Doe but only for the last_name23:53
dfamoratobechamel: ok, so for now, I should worry about building the tryton driver which will expose the search_rec name of the modules to be indexed by the indexer.... that is step 1, right ?23:54
dfamoratobechamel: and also knowing that we will have a get_rec_excerpt which also will be full-text indexed23:55
bechameldfamorato: yes23:55
bechameldfamorato: and does it asynchronously :)23:55
dfamoratodfamorato: yep... got it... ascynchronously without using a message queue..23:56
dfamoratobechamel: so.. i have a roadmap now... i will start working on this and i will keep you updated23:57
bechameldfamorato: you cannot do it without some kind of queue, but you can start with the python built-in queue23:57
dfamoratobechamel: yes... that is what i realized today after looking at my friend's code23:58
dfamoratobechamel: thanks for the help.. i have to leave now... i will keep you updated23:59
bechameldfamorato: ok23:59
bechameldfamorato: see you later23:59

Generated by 2.11.0 by Marius Gedminas - find it at!