IRC logs of #tryton for Thursday, 2019-05-23

chat.freenode.net #tryton log beginning Thu May 23 00:00:01 CEST 2019
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton23:20
-!- csotelo(~csotelo@190.234.41.50) has joined #tryton00:05
-!- yangoon(~mathiasb@i59F4A4E8.versanet.de) has joined #tryton02:02
-!- yangoon1(~mathiasb@i59F5FD6F.versanet.de) has joined #tryton03:00
-!- Westoluth(49fc9f72@gateway/web/freenode/ip.73.252.159.114) has joined #tryton03:16
-!- springwurm(~Springwur@5.104.149.54) has joined #tryton04:48
-!- Timitos(~kpreisler@host-88-217-184-172.customer.m-online.net) has joined #tryton05:58
-!- rpit(~rpit@p200300C88F0A6700F0BEFC50CEB0A731.dip0.t-ipconnect.de) has joined #tryton06:22
-!- mrichez(~Maxime@mail.saluc.com) has joined #tryton06:44
-!- kapilp(uid36151@gateway/web/irccloud.com/x-qzacmncypdqhvasq) has joined #tryton06:48
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton06:55
-!- thaneor(~lenovo3@r179-25-65-53.dialup.adsl.anteldata.net.uy) has joined #tryton07:14
-!- rpit(~rpit@p4FFB77B3.dip0.t-ipconnect.de) has joined #tryton07:53
-!- nicoe(~nicoe@host-85-201-184-151.dynamic.voo.be) has joined #tryton08:27
-!- kapilp(uid36151@gateway/web/irccloud.com/x-wdfjocwvzhyjskhq) has joined #tryton10:27
-!- mniip(mniip@freenode/staff/mniip) has joined #tryton10:40
-!- csotelo(~csotelo@190.234.41.50) has joined #tryton11:04
-!- mariomop(~quassel@host208.201-253-199.telecom.net.ar) has joined #tryton11:12
mrichezhi, with trytond.application app , can we define an optional parameter in a route ? @app.route('/<database_name>/lot/<lotnumber>/search/<location is an optional parameter>', methods=['GET'])12:25
-!- springwurm(~Springwur@5.104.149.54) has joined #tryton12:29
pokolimrichez: You can follow the same pattern as flask https://stackoverflow.com/questions/14032066/can-flask-have-optional-url-parameters12:31
mrichezpokoli: ok thanks, will try this way (so i can use @app.route decorator multiple times on the same method)12:33
pokolimrichez: yes, it is used to expose the same method to multiple endpoints12:34
mrichezpokoli: :-) thanks!12:34
mrichezpokoli: TypeError: route() got an unexpected keyword argument 'defaults'13:11
pokolimrichez: have you tried removing default and using a default value for the parameter on the function?13:14
pokoliis the second solution proposed on the above SO question I posted13:15
mrichezpokoli: ok working with default value parameter13:20
-!- csotelo(~csotelo@190.234.41.50) has joined #tryton13:36
-!- mrichez(~Maxime@mail.saluc.com) has joined #tryton13:45
-!- mariomop(~quassel@host208.201-253-199.telecom.net.ar) has joined #tryton17:59
-!- thaneor1(~lenovo3@179.26.4.58) has joined #tryton19:17
-!- semarie(~semarie@unaffiliated/semarie) has joined #tryton20:00

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