IRC logs of #tryton for Sunday, 2016-08-21

chat.freenode.net #tryton log beginning Sun Aug 21 00:00:01 CEST 2016
-!- sebd(~seb@aditu.ldd.fr) has joined #tryton00:05
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton00:32
-!- shrox(shrox@nat/iiit/x-qpuesxmupejfgpyz) has joined #tryton02:37
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton03:09
-!- kstenger(~karla@r190-134-148-229.dialup.adsl.anteldata.net.uy) has joined #tryton04:01
-!- cch__(~clews@188-23-206-131.adsl.highway.telekom.at) has joined #tryton08:41
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton08:43
-!- rpit(~rpit@aftr-37-24-146-168.unity-media.net) has joined #tryton08:45
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton08:51
-!- udono(~udono@ip-37-201-245-214.hsi13.unitymediagroup.de) has joined #tryton10:40
-!- scrapper(~scrapper@88.117.159.6) has joined #tryton11:01
-!- Telesight(~anthony@4dae0c97.ftth.telfortglasvezel.nl) has joined #tryton12:11
-!- rpit(~rpit@2a02:908:e674:5940:56ee:75ff:fe0d:d3c7) has joined #tryton17:01
-!- shrox1(shrox@nat/iiit/x-ioujlhteoodweytg) has joined #tryton17:10
shrox1cedk: "I do not think it is a good API to work with filename, it is better to work with file object like that is can be used with in-memory data." How do I proceed?17:17
shrox1cedk: I don't know how to take an input FOD if not by filename.17:18
cedkshrox1: I'm talking about the API, not the command line17:21
shrox1 /msg nickserv identify shrox ircisnice17:22
shrox1cedk: What change do you want me to do?17:23
cedkshrox1: to not work at API level with filename17:24
shrox1cedk: I don't know what you mean by API level. If you can tell me in terms of what I'm doing right now, I'll understand better.17:25
cedkshrox1: by API, I mean when function are called17:26
-!- hispanic1234(0e8b5206@gateway/web/cgi-irc/kiwiirc.com/ip.14.139.82.6) has joined #tryton17:27
shrox1cedk: Okay. So I will use the file name only in __main__  ?17:32
shrox1cedk: but if I want to import fod2od and use convert directly, I won't be able to do so using only the filename17:33
cedkshrox1: yes, __main__ should only be boilerplat between command line and API17:33
cedkshrox1: often filename usage for API is useless17:34
cedkshrox1: but using fileobject API, it is easy to convert filename in such object17:34
-!- shrox(shrox@nat/iiit/x-cppsxwzggxakzrgj) has joined #tryton17:35
shroxcedk: the only concern I have is for when fod2py is imported into another program. __main__ will not be accessed, so the argument for convert will have to change accordingly.17:37
cedkshrox: I do not understand17:38
cedkshrox: __main__ will contain only simple boilerplt17:39
shroxcedk: I simply mean that this will not work if the filename is not an argument for convert - http://pastebin.ubuntu.com/23075850/17:42
cedkshrox: I do not understand what you mean17:44
shroxcedk: __name__ == _main_ only when fod2od is the main program, correct?17:45
shroxcedk: so if fod2od is *not* the main program, the file name cannot be used to identify the file if I the convert function does not use it as an argument17:46
cedkshrox: but I also think the method should not write file17:48
cedkshrox: it should be done in __main__ also17:48
cedkshrox: this is still API17:48
shroxcedk: Should I use StringIO in __main__ and then pass that as an argument for convert function?17:50
cedkshrox: Why?17:50
cedkshrox: for me, fileobject-like is enough17:50
shroxcedk: I'm sorry, I do not know what you mean by fileobject-like.17:52
cedkshrox: it is any kind of object who has the same API as fileobject17:55
cedkshrox: https://docs.python.org/2/library/stdtypes.html#bltin-file-objects17:55
shroxcedk: Okay, so you only want me to use the filename and get the file object in __main__ itself and not in parse_fod as I am doing right now?17:56
cedkshrox: yes18:02
shroxcedk: Okay. That's easy to do, haha.18:03
-!- nramirezuy(~nramirezu@r167-62-105-140.dialup.adsl.anteldata.net.uy) has joined #tryton18:41
-!- LordVan(~lordvan@gentoo/developer/LordVan) has joined #tryton21:01
-!- nicoe(~nicoe@109.132.45.119) has joined #tryton22:12
-!- shrox(shrox@nat/iiit/x-sbmhknkcvlfjuhzr) has joined #tryton22:33

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