IRC logs of #tryton for Tuesday, 2014-03-04

chat.freenode.net #tryton log beginning Tue Mar 4 00:00:03 CET 2014
2014-03-04 00:53 -!- pokoli(~pokoli@unaffiliated/pokoli) has joined #tryton
2014-03-04 01:30 -!- cedk(~ced@gentoo/developer/cedk) has joined #tryton
2014-03-04 02:11 -!- myrdd`(~myrdd@55d41a76.access.ecotel.net) has joined #tryton
2014-03-04 02:51 -!- digitalsatori(~Thunderbi@116.234.234.90) has joined #tryton
2014-03-04 03:04 -!- digitalsatori(~Thunderbi@116.234.234.90) has joined #tryton
2014-03-04 04:12 -!- hyances(~humberto@181.141.36.235) has joined #tryton
2014-03-04 05:17 -!- hyances(~humberto@181.141.36.235) has joined #tryton
2014-03-04 05:32 -!- sharoonthomas(~sharoonth@122.177.232.208) has joined #tryton
2014-03-04 05:50 -!- sharoonthomas(~sharoonth@122.177.232.208) has joined #tryton
2014-03-04 06:02 -!- yangoon1(~mathiasb@p549F1E1B.dip0.t-ipconnect.de) has joined #tryton
2014-03-04 06:22 -!- sharoonthomas(~sharoonth@123.239.108.42) has joined #tryton
2014-03-04 06:35 -!- sharoonthomas(~sharoonth@122.177.232.208) has joined #tryton
2014-03-04 06:44 -!- frispete(~frispete@p54A93F67.dip0.t-ipconnect.de) has joined #tryton
2014-03-04 07:03 -!- littlebit(~Thunderbi@ulmg-4d022669.pool.mediaWays.net) has joined #tryton
2014-03-04 07:11 -!- sharoonthomas_(~sharoonth@122.177.71.143) has joined #tryton
2014-03-04 07:13 -!- udono(~udono@ip-88-152-168-173.unitymediagroup.de) has joined #tryton
2014-03-04 08:29 -!- corro(~corro@46.22.23.85) has joined #tryton
2014-03-04 08:39 -!- jeancavallo(~giovanni@LVelizy-156-46-68-52.w80-12.abo.wanadoo.fr) has joined #tryton
2014-03-04 08:41 -!- jvblasco(~seba@62.43.196.37.static.user.ono.com) has joined #tryton
2014-03-04 09:09 -!- jvblasco(~seba@62.43.196.37.static.user.ono.com) has joined #tryton
2014-03-04 09:11 -!- digitalsatori(~Thunderbi@116.234.38.194) has joined #tryton
2014-03-04 09:43 -!- nicoe(~nicoe@2001:6f8:3aa:0:b699:baff:fe56:2328) has joined #tryton
2014-03-04 09:46 -!- cedk(~ced@gentoo/developer/cedk) has joined #tryton
2014-03-04 10:03 -!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton
2014-03-04 10:25 -!- pobsteta(~Thunderbi@4cb54-3-88-160-87-54.fbx.proxad.net) has joined #tryton
2014-03-04 10:26 -!- sharoonthomas(~sharoonth@122.177.254.5) has joined #tryton
2014-03-04 10:40 <pokoli> sharoonthomas: it's not possible to have a per site base.jinja for nereid_webshop? I can't manage to override it's logo block
2014-03-04 10:51 <sharoonthomas> pokoli: its possible
2014-03-04 10:52 <sharoonthomas> pokoli: you can have a folder in the templates directory with the 'name' of the website
2014-03-04 10:52 <sharoonthomas> pokoli: nereid first looks for the website template folder, followed by the root template folder
2014-03-04 10:56 <pokoli> sharoonthomas: that's what i'm doing for home.jinja, but it doesn't work with base.jinja
2014-03-04 10:56 <pokoli> sharkcz: maybe I'm missing something :S
2014-03-04 10:56 <pokoli> sharkcz: sorry, i was talking to sharoonthomas
2014-03-04 10:57 <sharoonthomas> pokoli: i think I know why... in your home.jinja can you change the extends line ?
2014-03-04 10:57 <sharoonthomas> pokoli: {% extends request.nereid_website.name + '/base.jinja' %}
2014-03-04 10:58 <pokoli> sharoonthomas: home.jinja is working perfectly
2014-03-04 10:58 <pokoli> sharoonthomas: I try to have a customized logo per webside, so I override the logo block in base.jinja
2014-03-04 10:59 <pokoli> sharoonthomas: But i get the old logo. If I override home.jinja, the logo gets displayed on the home page but not on the other pages
2014-03-04 10:59 <pokoli> sharoonthomas: so I'm wondering how to change the logo for all pages
2014-03-04 11:00 <sharoonthomas> pokoli: am i right in thinking that the structure of your templates folder for the app is 1:'templates/', 2:`templates/site1/..`, 3:`templates/site2/...`
2014-03-04 11:00 <sharoonthomas> ?
2014-03-04 11:02 <pokoli> sharoonthomas: yes it is
2014-03-04 11:02 -!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton
2014-03-04 11:02 <sharoonthomas> pokoli: in that case create a templates/base.jinja with just one line {% extends request.nereid_website.name + '/base.jinja' %}
2014-03-04 11:02 <sharoonthomas> pokoli: and ensure that there is a base.jinja in each folder
2014-03-04 11:02 <pokoli> sharoonthomas: let me try :)
2014-03-04 11:04 <sharoonthomas> pokoli: template inheritance is a little tricky.... and we need some good documentation about these trivial cases
2014-03-04 11:07 <pokoli> sharoonthomas: worked perfectly! thanks
2014-03-04 11:11 <pokoli> sharoonthomas: you saved my a lot of time, because we where thinking in duplicating all the code in order to make logo work :P
2014-03-04 11:14 <sharoonthomas> pokoli: glad i could be of help... would be great if you add a gotcha or wiki of nereid webshop ?
2014-03-04 11:15 <pokoli> sharoonthomas: wiki not enabled for nereid-webshop
2014-03-04 11:16 <pokoli> sharoonthomas: If you can enable it i will try to document the issue :)
2014-03-04 11:17 -!- digitalsatori(~Thunderbi@116.234.38.194) has joined #tryton
2014-03-04 11:43 -!- Telesight(~anthony@77-175-168-222.FTTH.ispfabriek.nl) has joined #tryton
2014-03-04 11:51 -!- sharoonthomas(~sharoonth@122.177.254.5) has joined #tryton
2014-03-04 11:51 <sharoonthomas> pokoli: created
2014-03-04 11:51 -!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton
2014-03-04 12:03 <pokoli> sharoonthomas: here you have https://github.com/openlabs/nereid-webshop/wiki/Templating-tricks :)
2014-03-04 12:07 <sharoonthomas> pokoli: you are aware that you do not have to copy templates at all to a new application's template directory right? It picks up from tryton package folder
2014-03-04 12:08 -!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton
2014-03-04 12:08 <pokoli> sharoonthomas: I'm using the tryton package as template folder
2014-03-04 12:09 <sharoonthomas> pokoli: cool
2014-03-04 12:12 <pokoli> sharoonthomas: to use a custom folder I have to override the TEMPLATE config in application.py, don't I?
2014-03-04 12:12 <pokoli> sharoonthomas: I think you missed the link on the tweet :P
2014-03-04 12:17 -!- digitalsatori(~Thunderbi@116.234.38.194) has joined #tryton
2014-03-04 12:19 <sharoonthomas> pokoli: ah! hangover
2014-03-04 12:40 -!- mariomop(~quassel@186.153.79.166) has joined #tryton
2014-03-04 12:52 -!- pilou(~pilou@181.204.19.93.rev.sfr.net) has joined #tryton
2014-03-04 12:52 -!- pilou(~pilou@pdpc/supporter/active/pilou) has joined #tryton
2014-03-04 13:45 -!- hyances(~humberto@181.141.36.235) has joined #tryton
2014-03-04 14:01 -!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton
2014-03-04 14:27 -!- digitalsatori(~Thunderbi@114.92.199.176) has joined #tryton
2014-03-04 15:29 -!- vernichon(~Thunderbi@gex01-1-78-234-55-95.fbx.proxad.net) has joined #tryton
2014-03-04 15:50 -!- gremly(~gremly@190.85.36.58) has joined #tryton
2014-03-04 15:56 -!- smarro(~sebastian@190.105.85.74) has joined #tryton
2014-03-04 17:03 -!- digitalsatori(~Thunderbi@114.92.199.176) has joined #tryton
2014-03-04 17:22 -!- sharoonthomas(~sharoonth@123.63.144.247) has joined #tryton
2014-03-04 17:35 -!- gremly(~gremly@190.85.36.58) has joined #tryton
2014-03-04 17:55 <pokoli> anyone knows if there are some issues with numeric search on sqlite?
2014-03-04 17:55 <pokoli> I'm searching for lines with debit <= Decimal('75') and I'm getting lines with debit 100
2014-03-04 18:02 -!- digitalsatori(~Thunderbi@114.92.199.176) has joined #tryton
2014-03-04 18:03 -!- smarro(~sebastian@190.105.85.74) has joined #tryton
2014-03-04 18:12 <yangoon1> pokoli: what do you get with: debit <= 75 ?
2014-03-04 18:12 <pokoli> yangoon1 the correct result
2014-03-04 18:13 <yangoon1> pokoli: http://www.sqlite.org/datatype3.html
2014-03-04 18:14 <pokoli> yangoon1: thanks, I'm wondering if this will cause problems on postgresql :(
2014-03-04 18:18 <pokoli> yangoon1: trytond expects Decimal, so I can not cast :(
2014-03-04 18:19 <yangoon1> pokoli: do you access via trytond/python-sql?
2014-03-04 18:20 <pokoli> yangoon1: Yes, I'm doing a search on account.move.line
2014-03-04 18:20 <yangoon1> pokoli: weird, sounds like a bug
2014-03-04 18:22 <cedk> pokoli: they are unittest about searching numerci fields
2014-03-04 18:23 <cedk> pokoli: did you look at the real SQL query executed?
2014-03-04 18:24 <pokoli> cedk: I know about unit test, I executed it on my local server and they passed
2014-03-04 18:24 <pokoli> cedk: So I'm wondering if the unit test still miss something
2014-03-04 18:24 <pokoli> cedk: I have the python-sql generated tuple
2014-03-04 18:25 <cedk> pokoli: how the debit was filled?
2014-03-04 18:26 <pokoli> cedk: http://pastebin.com/Px0RPwJH
2014-03-04 18:27 <pokoli> cedk: the debit field is filled by another account.move.line instance
2014-03-04 18:27 <pokoli> cedk: something like ('credit', '<=', line.credit)
2014-03-04 18:29 <cedk> pokoli: that doesn't fill anything
2014-03-04 18:29 <pokoli> ACTION is wondering why they case breaks and doesn't break on unitest
2014-03-04 18:29 <pokoli> cedk: what do you mean by fill?
2014-03-04 18:32 <cedk> pokoli: created
2014-03-04 18:32 <pokoli> cedk: 'debit': Decimal(30),
2014-03-04 18:33 <pokoli> cedk: maybe If i use Decimal('30.0') should work properly?
2014-03-04 18:34 <cedk> pokoli: how is it in SQLite?
2014-03-04 18:39 <pokoli> cedk: http://pastebin.com/533gFG8i
2014-03-04 18:40 <pokoli> ids 2 and 4 are the ids of the results i get, id 8 is the line where i get the credit to generate the domain
2014-03-04 18:41 <cedk> pokoli: I guess your search query is too complex for the data interpolation of sqlite
2014-03-04 18:41 <pokoli> cedk: that's the domain i'm searching for [('reconciliation', '=', None), ('account', '=', Pool().get('account.account')(5)), ('debit', '<=', Decimal('75')), ('credit', '=', 0)]
2014-03-04 18:43 <cedk> credit = 0 is useless
2014-03-04 18:47 <cedk> pokoli: indeed I suspect sqlite to do a string comparison
2014-03-04 18:47 <pokoli> cedk: Just replaced with ('debit', '!=', 0), which is wath I'm searching for and I get the same problem :P
2014-03-04 18:48 <cedk> pokoli: so '100' <= '75'
2014-03-04 18:48 <pokoli> cedk: I will try to create a test case and fill a bug with the test case
2014-03-04 18:50 <cedk> pokoli: I'm not sure we will be able to fix sqlite
2014-03-04 18:52 <pokoli> cedk: I understand, no problem
2014-03-04 18:54 <cedk> pokoli: perhaps casting both side into float for search?
2014-03-04 18:57 <pokoli> cedk: thay may do the trick
2014-03-04 18:57 <cedk> pokoli: or succeeded to get sqlite compare string like this: '100' > '075'
2014-03-04 18:59 <pokoli> cedk: I think it's easier to cast
2014-03-04 18:59 <cedk> pokoli: or ask sqlite maintainer about this
2014-03-04 19:00 <pokoli> cedk: Here is the breaking test http://codereview.tryton.org/4061002/
2014-03-04 19:01 <cedk> we store in Decimal as blob: http://hg.tryton.org/trytond/file/c6a22da9182e/trytond/backend/sqlite/database.py#l397
2014-03-04 19:02 <cedk> otherwise they are stored as float and we get rounding issue
2014-03-04 19:02 <cedk> pokoli: I would prefer to add a new test case
2014-03-04 19:03 <cedk> pokoli: instead of changing existing
2014-03-04 19:05 <pokoli> cedk: I will create new one :)
2014-03-04 19:11 -!- ArtGravity(~artgravit@2602:47:d89d:b600:79fd:c794:99f8:8a4f) has joined #tryton
2014-03-04 19:14 <pokoli> cedk: just uploaded the new test case
2014-03-04 19:15 <pokoli> cedk: if stored as blob they can be casted as float?
2014-03-04 19:17 -!- azi(~azi@c-69-181-105-205.hsd1.ca.comcast.net) has joined #tryton
2014-03-04 19:22 <azi> I'm trying to connect to a tryton server on a linode. i've installed tryton 2.2.4 via debian stable aptitude, created my pg user/pass, updated /etc/trytond.conf with the pg settings and /etc/init.d/trytond restart, but the client still says 'no server detected' when i try to access the ip. if I turn on web-dav on 8080 and restart, I get an empty http site at server:8080, but still nothing on :8000. Ive tried setting the log setting in /etc
2014-03-04 19:22 <azi> Is there anyone on here with the expertise and a moment to point me in the right direction? I would be hugely appreciative.
2014-03-04 19:24 <yangoon1> azi: first of all, version 2.2 is quite outdated, I would recommend a backport from debian.tryton.org
2014-03-04 19:25 <azi> Understood and thanks for the reply!
2014-03-04 19:25 <yangoon1> azi: feel free to ask again if you still run into problems
2014-03-04 19:25 <azi> My default mo is to work with the version in repo until i need something greater, but i'll pull the latest.
2014-03-04 19:25 <azi> copy, thanks for the responsiveness:)
2014-03-04 19:25 <pokoli> azi: I will recomend you 3.0 :P
2014-03-04 19:26 <yangoon1> azi in case you didn't know: http://code.google.com/p/tryton/wiki/InstallationOnDebian
2014-03-04 19:31 <pokoli> cedk: casting on both sides seems to do the trick for solving the issue
2014-03-04 19:36 <azi> Thanks yangoon, i've had that open in the back, i just hadn't thought to check the repo versions... upgrading to 3.0 now.
2014-03-04 19:56 -!- vcardon1(~vcardon@LNeuilly-152-23-15-185.w193-252.abo.wanadoo.fr) has left #tryton
2014-03-04 19:56 <azi> Ok, so I'm running tryton-server v3.0.2 with no modules as downloaded from debian.tryton.org for wheezy on the linode, and tryton-client v3.0.1 from same source on my dev machine. I've set the PG settings in /etc/trytond.conf and restarted to the following log: [Tue Mar 04 18:51:20 2014] INFO:server:stopped
2014-03-04 19:56 <azi> [Tue Mar 04 18:51:21 2014] INFO:server:using /etc/trytond.conf as configuration file
2014-03-04 19:56 <azi> [Tue Mar 04 18:51:21 2014] INFO:server:initialising distributed objects services
2014-03-04 19:56 <azi> [Tue Mar 04 18:51:21 2014] INFO:server:starting JSON-RPC protocol on localhost:8000
2014-03-04 19:56 <azi> however, when I go to the client, put in the server url and port 8000, I still get 'unable to connect to database' :-/
2014-03-04 19:57 <azi> do I need to explicitly start the server at ip:8000 instead of localhost:8000?
2014-03-04 19:57 <yangoon1> azi if you are not on the same host, put :8000 in trytond.conf
2014-03-04 19:58 <yangoon1> server currently listens on localhost
2014-03-04 19:59 <yangoon1> azi: and if you are not able to connect to the database, there still could something be misssing in your postgres setup (pg_hba.conf)
2014-03-04 20:00 <azi> Ok... we're getting places. now when I try to connect, a progress bar shows up and then quickly disappears to the same 'Could not connect to the server' but the server logs :[Tue Mar 04 18:58:50 2014] INFO:database:connect to "template1"
2014-03-04 20:00 <azi> rechecking postgres configuration
2014-03-04 20:01 <yangoon1> azi: finally you seem to be ready to create your first tryton database;)
2014-03-04 20:02 <azi> checking pg_hba.conf, as I am still getting 'cannot connect' in the profile manager.
2014-03-04 20:11 -!- azi(~azi@173-164-176-58-SFBA.hfc.comcastbusiness.net) has joined #tryton
2014-03-04 20:17 <azi> OK... I modified pg_hba.conf to allow host all all 0.0.0.0/0, restarted pg and the server, but I'm in the same spot.
2014-03-04 20:18 <azi> pg_hba.conf: #host all all 127.0.0.1/32 md5
2014-03-04 20:18 <azi> host allall0.0.0.0/0md5
2014-03-04 20:19 <yangoon1> azi: do you have a tryton role in the postgres?
2014-03-04 20:19 <azi> still getting [Tue Mar 04 19:16:40 2014] INFO:database:connect to "template1" every time I click on my 'test_tryton_server' profile. The progress bar loads for an instant, but then returns 'unable to connect', I'm going to see if I an find a client log
2014-03-04 20:20 <azi> I have one that I configured, client_tryton, as specified in the guide.
2014-03-04 20:20 <yangoon1> azi: does it have a password?
2014-03-04 20:21 <azi> yes. for the hell of it, I'm going to redo that whole portion of the program with a new user
2014-03-04 20:21 <azi> just to make sure I recalled the password correctly.
2014-03-04 20:23 <azi> Shall the new roll be allowed to create new roles? no, correct?
2014-03-04 20:23 <yangoon1> no, it just needs permissions to create databases
2014-03-04 20:24 <yangoon1> if you want to do so;), so usually yes
2014-03-04 20:27 <azi> hmm... I seem to have totally missed the last line of tryton/wiki/setupandstart:
2014-03-04 20:27 <azi> Create a databaseCancel login windowClick on File>Database>New DatabaseFill the form and click on CreateLogin with the user "admin"
2014-03-04 20:28 <azi> when adding the new database, it asks for a password it says is in /etc/trytond.conf, yet when I scan it I can't see it, and the database password doesn't work.
2014-03-04 20:28 <yangoon1> azi: :) (20:01:48) yangoon: azi: finally you seem to be ready to create your first tryton database;)
2014-03-04 20:29 <yangoon1> azi: password of tryton server is in trytond.conf and by default 'admin'
2014-03-04 20:29 -!- pablovannini(~pablo@190.55.77.17) has joined #tryton
2014-03-04 20:37 -!- littlebit(~Thunderbi@ulmg-4d022669.pool.mediaWays.net) has joined #tryton
2014-03-04 20:45 <azi> Almost there!
2014-03-04 20:46 <azi> The database creation worked, then when I went to profiles and clicked, it could see the database!
2014-03-04 20:47 <azi> seems like the only thing I'm missing is the default admin password.
2014-03-04 20:48 <azi> yangoon1, thank you so much for your help
2014-03-04 20:48 <azi> I'm in!
2014-03-04 20:48 <yangoon1> azi for login you use the password you provided for the database (while creating it)
2014-03-04 20:48 <yangoon1> azi: welcome!
2014-03-04 20:54 -!- predatell(~predatell@176.122.125.176) has joined #tryton
2014-03-04 21:10 -!- mariomop(~quassel@186.153.79.166) has joined #tryton
2014-03-04 22:07 -!- littlebit(~Thunderbi@ulmg-4d022669.pool.mediaWays.net) has joined #tryton

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!