On Tue, Oct 4, 2016 at 1:03 PM, Manish Tomar wrote:
> I was on synchronous mindset before learning Twisted and did not
> like/understand Deferred. The `yield` based statement really helped me
> initially but more importantly over time I liked seeing an explicit
> difference between blocking vs non
On Tue, Oct 4, 2016 at 12:42 PM, meejah wrote:
> Oon-Ee Ng writes:
>
>> The closest I'm able to come to that so far is for my function to be
>> decorated with @defer.inlineCallbacks which will then look like this
>>
>> val = yield doSomeCallRemoteCallHere(args)
>> myWidget.text = val
>
>
On Mon, Oct 3, 2016 at 8:55 PM, Oon-Ee Ng wrote:
> Is this as 'good' (for the subjective readability concern) as it gets?
> I'm basically going for sufficient readability that my UI code can be
> read by programmers stuck in a synchronous mindset.
I was on synchronous mindset before learning Twis
Oon-Ee Ng writes:
> The closest I'm able to come to that so far is for my function to be
> decorated with @defer.inlineCallbacks which will then look like this
>
> val = yield doSomeCallRemoteCallHere(args)
> myWidget.text = val
You can even do "myWidget.text = yield somethingDeferred()"