Re: [Tutor] changing a variable with raw_input

2015-09-16 Thread Mark Lawrence
On 16/09/2015 18:14, richard kappler wrote: Nevermind, figured it out. it needed to be delay = 0 and delay = 0.5, not == regards, Richard the virus ridden On Wed, Sep 16, 2015 at 1:03 PM, richard kappler wrote: Missing something obvious here, but down with the flu so I'm foggy and just can't

Re: [Tutor] changing a variable with raw_input

2015-09-16 Thread richard kappler
Nevermind, figured it out. it needed to be delay = 0 and delay = 0.5, not == regards, Richard the virus ridden On Wed, Sep 16, 2015 at 1:03 PM, richard kappler wrote: > Missing something obvious here, but down with the flu so I'm foggy and > just can't see it. I need to set a variable 'delay' t

[Tutor] changing a variable with raw_input

2015-09-16 Thread richard kappler
Missing something obvious here, but down with the flu so I'm foggy and just can't see it. I need to set a variable 'delay' to be used in time.sleep(delay) later on in a script, based on user input. Something odd is going on in setting the variable though. Here's the snippet where I'm trying to set

Re: [Tutor] Is context manager the answer to synchronous function calls?

2015-09-16 Thread Mark Lawrence
On 16/09/2015 11:56, Alan Gauld wrote: On 16/09/15 01:46, John Wong wrote: def create_vm(.): # returns vm object def modify_vm(.): return new vm object def get_vm_status(.): return status # Constraints: # I cannot modify vm until vm is finished, # I also cannot modif

Re: [Tutor] Is context manager the answer to synchronous function calls?

2015-09-16 Thread Alan Gauld
On 16/09/15 01:46, John Wong wrote: def create_vm(.): # returns vm object def modify_vm(.): return new vm object def get_vm_status(.): return status # Constraints: # I cannot modify vm until vm is finished, # I also cannot modify VM while the VM is being updated. # Ob

[Tutor] Is context manager the answer to synchronous function calls?

2015-09-16 Thread John Wong
Hi Here is the code: def create_vm(.): # returns vm object def modify_vm(.): return new vm object def get_vm_status(.): return status # Constraints: # I cannot modify vm until vm is finished, # I also cannot modify VM while the VM is being updated. # Obviously it looks u