Re: Decorator

2017-02-08 Thread Chris Angelico
On Thu, Feb 9, 2017 at 6:03 PM, ast wrote: > class Temperature: > def __init__(self): >self.value = 0 > > # @property >def celsius(self):return self.value > celsius = property(celsius) > # @celsius.setter def celsius(self, value):<-- > overwri

Decorator

2017-02-08 Thread ast
Hi In python courses I read, it is explained that @decor def f(): pass is equivalent to: def f(): pass f = decor(f) But that's not always true. See this code class Temperature: def __init__(self): self.value = 0 # @property def celsius(self): return self.va

Re: subprocess problem

2017-02-08 Thread Cameron Simpson
On 08Feb2017 18:56, Andreas Paeffgen wrote: The Problem with the subprocess code is: Using the sourcecode functioning as normal. The frozen app with cx_freeze on every platform just returns an empty result I don't know what the sentence above above cx_freeze means. Here is the code in short

subprocess problem

2017-02-08 Thread Andreas Paeffgen
The Problem with the subprocess code is: Using the sourcecode functioning as normal. The frozen app with cx_freeze on every platform just returns an empty result Here is the code in short: def get_path_pandoc(): settings = QSettings('Pandoc', 'PanConvert') path_pandoc = settings.value

Re: Coding issue with XML for word document

2017-02-08 Thread accessnewbie
> myBlurb = "My Favorite Cars - > My favorite cars are available at " + > myText + " > > What am I missing here? Sorry about posting in python group. My XML coding was embedded in python script. I will do better next time. The problem was with placement of tags. The following worked: myB

Re: How to store properties

2017-02-08 Thread Terry Reedy
On 2/8/2017 6:26 AM, Cecil Westerhof wrote: In Java you (can) use a properties file store configuration. What is the best way to do something like that in Python? I saw ConfigParser, but have the feeling that it is not really used. IDLE uses it for default and user configuration files. -- Ter

RE: gmail api

2017-02-08 Thread Deborah Swanson
Kelvid Pang wrote, on February 06, 2017 10:22 PM > > hi, > > I am trying to gmail api with reference to this URL: > https://developers.google.com/gmail/api/quickstart/python > > > But I couldn't find the > 'gmail-python-quickstart.json' file. Any one can help? thanks. You likely won't have a

Re: How to store properties

2017-02-08 Thread Cecil_Westerhof
From: Cecil Westerhof On Wednesday 8 Feb 2017 13:11 CET, Peter Heitzer wrote: > Cecil Westerhof wrote: >> In Java you (can) use a properties file store configuration. What >> is the best way to do something like that in Python? I saw >> ConfigParser, but have the feeling that it is not really

Re: Coding issue with XML for word document

2017-02-08 Thread Pavol_Lisy
From: Pavol Lisy On 2/7/17, Steven D'Aprano wrote: > On Mon, 06 Feb 2017 17:00:25 -0800, accessnewbie wrote: [...] >> But when I try to bold, it bombs. It does not seem to like either of >> these (+ myText + "") (separately or together) appended on the >> end. > > How are you trying to bold? If

Re: How to store properties

2017-02-08 Thread Michael_Torrie
From: Michael Torrie On 02/08/2017 04:26 AM, Cecil Westerhof wrote: > In Java you (can) use a properties file store configuration. What is > the best way to do something like that in Python? > I saw ConfigParser, but have the feeling that it is not really used. > Would a JSON file be a good idea?

Re: Coding issue with XML for word document

2017-02-08 Thread Deborah_Swanson
From: Deborah_Swanson@f38.n261.z1 From: Deborah_Swanson@f38.n261.z1 From: "Deborah Swanson" I don't see any Python in your code. The python.org list isn't generally familiar with Microsoft proprietary code, which is often quite different from other versions. Try asking this question in Microsof

Re: search for a data in my browser via script

2017-02-08 Thread kelvidpang
From: kelvidpang@f38.n261.z1 From: kelvidpang@f38.n261.z1 From: kelvidp...@gmail.com On Monday, 6 February 2017 22:43:17 UTC+8, Meeran Rizvi wrote: > Hello guys, > Here i am writing a script which will open my chrome browser and opens the URL www.google.com. > But how to search for a data via s

Re: Coding issue with XML for word document

2017-02-08 Thread Deborah_Swanson
From: "Deborah Swanson" Cute, whoever you are. Very cute. (I know how to sign up for fake email addresses too.) > -Original Message- > From: Python-list > [mailto:python-list-bounces+python=deborahswanson.net@python.o > rg] On Behalf Of Deborah_Swanson@f38.n261.z1 > Sent: Monday, Februar

Re: How to add months to a date (datetime object)?

2017-02-08 Thread John_Gordon
From: John_Gordon@f38.n261.z1 From: John_Gordon@f38.n261.z1 From: John Gordon In "Deborah Swanson" writes: > bajimicb...@gmail.com wrote, on February 02, 2017 2:44 AM > > > > for start of month to the beginning of next month > > > > from datetime import timedelta > > from dateutil.relativede

Re: How to store properties

2017-02-08 Thread Rob Gaddi
On 02/08/2017 03:26 AM, Cecil Westerhof wrote: In Java you (can) use a properties file store configuration. What is the best way to do something like that in Python? I saw ConfigParser, but have the feeling that it is not really used. Would a JSON file be a good idea? In the interest of trying

Re: How to store properties

2017-02-08 Thread Michael Torrie
On 02/08/2017 04:26 AM, Cecil Westerhof wrote: > In Java you (can) use a properties file store configuration. What is > the best way to do something like that in Python? > I saw ConfigParser, but have the feeling that it is not really used. > Would a JSON file be a good idea? I've used ConfigParse

Re: How to store properties

2017-02-08 Thread Neil Cerutti
On 2017-02-08, Cholo Lennon wrote: > On 02/08/2017 08:26 AM, Cecil Westerhof wrote: >> In Java you (can) use a properties file store configuration. >> What is the best way to do something like that in Python? I >> saw ConfigParser, but have the feeling that it is not really >> used. > > I use it a

Re: How to store properties

2017-02-08 Thread Cecil Westerhof
On Wednesday 8 Feb 2017 13:11 CET, Peter Heitzer wrote: > Cecil Westerhof wrote: >> In Java you (can) use a properties file store configuration. What >> is the best way to do something like that in Python? I saw >> ConfigParser, but have the feeling that it is not really used. >> Would a JSON fi

Re: How to store properties

2017-02-08 Thread David Palao
2017-02-08 13:34 GMT+01:00 Cholo Lennon : > On 02/08/2017 08:26 AM, Cecil Westerhof wrote: >> >> In Java you (can) use a properties file store configuration. What is >> the best way to do something like that in Python? >> I saw ConfigParser, but have the feeling that it is not really used. > > > I

Re: How to store properties

2017-02-08 Thread Cholo Lennon
On 02/08/2017 08:26 AM, Cecil Westerhof wrote: In Java you (can) use a properties file store configuration. What is the best way to do something like that in Python? I saw ConfigParser, but have the feeling that it is not really used. I use it a lot ;-) Would a JSON file be a good idea? -

Re: How to store properties

2017-02-08 Thread Peter Heitzer
Cecil Westerhof wrote: >In Java you (can) use a properties file store configuration. What is >the best way to do something like that in Python? >I saw ConfigParser, but have the feeling that it is not really used. >Would a JSON file be a good idea? If you only want to read the configuration, just

How to store properties

2017-02-08 Thread Cecil Westerhof
In Java you (can) use a properties file store configuration. What is the best way to do something like that in Python? I saw ConfigParser, but have the feeling that it is not really used. Would a JSON file be a good idea? -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.c

Re: Python Events in 2017, Need your help.

2017-02-08 Thread Stephane Wirtel via Python-list
Thank you, with your help, we have added events on the t-shirt. Now, Could you just add them on python.org/events ? Have a nice day, Stephane On 9 Jan 2017, at 10:54, Stephane Wirtel via Python-list wrote: Dear Community, For the PythonFOSDEM [1] on 4th and 5th February in Belgium, I would