Alan Bawden :
> Marko Rauhamaa writes:
>> def fun():
>> f = open("lock")
>> flock.flock(f, fcntl.LOCK_EX)
>> do_stuff()
>> sys.exit(0)
>>
>> Question: can a compliant Python implementation close f (and,
>> consequently, release the file lock) before/while do_s
On Wednesday, February 27, 2019 at 11:12:28 AM UTC+5:30, Rustom Mody wrote:
> Ref: This stackexchange post:
> https://unix.stackexchange.com/q/503241/323121
>
> Context: Theres this guy who's really struggling with disk partitioning LVM
> etc concepts. That point is not directly relevant to this
Ref: This stackexchange post:
https://unix.stackexchange.com/q/503241/323121
Context: Theres this guy who's really struggling with disk partitioning LVM etc
concepts. That point is not directly relevant to this question.
My answer on that post tries to clarify that 'label' can mean 3 things at
Chris Angelico於 2019年2月27日星期三 UTC+8上午11時29分04秒寫道:
> On Wed, Feb 27, 2019 at 2:21 PM wrote:
> >
> > Chris Angelico於 2019年2月27日星期三 UTC+8上午9時25分11秒寫道:
> > > On Wed, Feb 27, 2019 at 12:21 PM wrote:
> > > >
> > > > Gregory Ewing at 2019/2/27 AM 5:26:49 wrote:
> > > > > Thomas Jollans wrote:
> > > > >
On Wed, Feb 27, 2019 at 2:21 PM wrote:
>
> Chris Angelico於 2019年2月27日星期三 UTC+8上午9時25分11秒寫道:
> > On Wed, Feb 27, 2019 at 12:21 PM wrote:
> > >
> > > Gregory Ewing at 2019/2/27 AM 5:26:49 wrote:
> > > > Thomas Jollans wrote:
> > > > > I imagine there's a justification for the difference in behaviou
Chris Angelico於 2019年2月27日星期三 UTC+8上午9時25分11秒寫道:
> On Wed, Feb 27, 2019 at 12:21 PM wrote:
> >
> > Gregory Ewing at 2019/2/27 AM 5:26:49 wrote:
> > > Thomas Jollans wrote:
> > > > I imagine there's a justification for the difference in behaviour to do
> > > > with the fact that the body of a class
Marko Rauhamaa writes:
> def fun():
> f = open("lock")
> flock.flock(f, fcntl.LOCK_EX)
> do_stuff()
> sys.exit(0)
>
> Question: can a compliant Python implementation close f (and,
> consequently, release the file lock) before/while do_stuff() is
> executed?
A
On Wed, Feb 27, 2019 at 12:21 PM wrote:
>
> Gregory Ewing at 2019/2/27 AM 5:26:49 wrote:
> > Thomas Jollans wrote:
> > > I imagine there's a justification for the difference in behaviour to do
> > > with the fact that the body of a class is only ever executed once, while
> > > the body of a functi
On 2/26/19, Gregory Ewing wrote:
> Thomas Jollans wrote:
>> I imagine there's a justification for the difference in behaviour to do
>> with the fact that the body of a class is only ever executed once, while
>> the body of a function is executed multiple times.
>
> I suspect there isn't any deep r
Gregory Ewing at 2019/2/27 AM 5:26:49 wrote:
> Thomas Jollans wrote:
> > I imagine there's a justification for the difference in behaviour to do
> > with the fact that the body of a class is only ever executed once, while
> > the body of a function is executed multiple times.
>
> I suspect there i
On 2/26/2019 10:10 AM, vergos.niko...@gmail.com wrote:
I'm receiving the following error:
Traceback (most recent call last):
File "/usr/lib64/python3.6/site-packages/bottle.py", line 862, in _handle
return route.call(**args)
File "/usr/lib64/python3.6/site-packages/bottle.py", line 17
On 2/26/19 3:54 PM, Marko Rauhamaa wrote:
> Consider this function:
>
> def fun():
> f = open("lock")
> flock.flock(f, fcntl.LOCK_EX)
> do_stuff()
> sys.exit(0)
>
> Question: can a compliant Python implementation close f (and,
> consequently, release the file l
On Wed, Feb 27, 2019 at 9:00 AM Marko Rauhamaa wrote:
> Consider this function:
>
> def fun():
> f = open("lock")
> flock.flock(f, fcntl.LOCK_EX)
> do_stuff()
> sys.exit(0)
>
> Question: can a compliant Python implementation close f (and,
> consequently, release
Consider this function:
def fun():
f = open("lock")
flock.flock(f, fcntl.LOCK_EX)
do_stuff()
sys.exit(0)
Question: can a compliant Python implementation close f (and,
consequently, release the file lock) before/while do_stuff() is
executed?
I couldn't find a
I have been a silent reader on this and am interested in understanding more
about the scope of variables in Python. They do not seem to behave as I
have experienced in other programming languages.
I have used functions in python but was not aware of class.
It would benefit me very well if someone
Thomas Jollans wrote:
I imagine there's a justification for the difference in behaviour to do
with the fact that the body of a class is only ever executed once, while
the body of a function is executed multiple times.
I suspect there isn't any deep reason for it, rather it's just
something that
On 26/02/2019 15:51, Paul Sutton wrote:
> Hi
>
> I have been trying to write a small application that is essentially user
> information application.
>
> https://raw.githubusercontent.com/zleap/AboutMe/master/Aboutme.py
>
> So far I have managed to write the data generated to a file, what I want
On Tue, 26 Feb 2019 15:51:38 +, Paul Sutton wrote:
> Hi
>
> I have been trying to write a small application that is essentially user
> information application.
>
> https://raw.githubusercontent.com/zleap/AboutMe/master/Aboutme.py
>
> So far I have managed to write the data generated to a file,
Actually i just found it has a directive:
dictrows: Whether or not to support dict-like access to row objects (default:
True).
so i just did:
plugin = bottle_pymysql.Plugin( dbuser='nikos', dbpass='*',
dbname='counters', dictrows=False )
and now it works with indexes as integers not as st
Τη Τρίτη, 26 Φεβρουαρίου 2019 - 5:21:14 μ.μ. UTC+2, ο χρήστης Calvin Spealman
έγραψε:
> you call it by visiting the route you've mapped to it, so when you run this
> app and navigate to the root / URL it gets called. What do you expect this
> parameter to be and where did you expect it to come fro
Hi
I have been trying to write a small application that is essentially user
information application.
https://raw.githubusercontent.com/zleap/AboutMe/master/Aboutme.py
So far I have managed to write the data generated to a file, what I want
to do now, is read this data back in when the user opens
Τη Τρίτη, 26 Φεβρουαρίου 2019 - 5:21:14 μ.μ. UTC+2, ο χρήστης Calvin Spealman
έγραψε:
> you call it by visiting the route you've mapped to it, so when you run this
> app and navigate to the root / URL it gets called. What do you expect this
> parameter to be and where did you expect it to come fro
you call it by visiting the route you've mapped to it, so when you run this
app and navigate to the root / URL it gets called. What do you expect this
parameter to be and where did you expect it to come from when you wrote the
listall() function?
On Tue, Feb 26, 2019 at 10:15 AM wrote:
> I'm rec
I'm receiving the following error:
Traceback (most recent call last):
File "/usr/lib64/python3.6/site-packages/bottle.py", line 862, in _handle
return route.call(**args)
File "/usr/lib64/python3.6/site-packages/bottle.py", line 1740, in wrapper
rv = callback(*a, **ka)
File "/usr/lib6
Τη Τρίτη, 26 Φεβρουαρίου 2019 - 3:26:29 μ.μ. UTC+2, ο χρήστης
vergos@gmail.com έγραψε:
> Can you help me rewrite this function, which when iam using 'pymysql'
> conncector works normally, it does not when iam using 'bottle_pymysql'
>
> def coalesce( data ):
> newdata = []
> seen
Can you help me rewrite this function, which when iam using 'pymysql'
conncector works normally, it does not when iam using 'bottle_pymysql'
def coalesce( data ):
newdata = []
seen = {}
for host, ref, location, useros, browser, visits, hits, downloads,
authuser in data:
On 25/02/2019 21.15, Chris Angelico wrote:
> On Tue, Feb 26, 2019 at 6:58 AM DL Neil
> wrote:
>>
>> On 26/02/19 5:25 AM, ast wrote:
>>> I noticed a quirk difference between classes and functions
>>> >>> x=0
>>> >>> class Test:
>>> x = x+1
>>> print(x)
>>> x = x+1
>>>
ast於 2019年2月26日星期二 UTC+8上午12時25分40秒寫道:
> Hello
>
> I noticed a quirk difference between classes and functions
>
> >>> x=0
> >>>
> >>> class Test:
> x = x+1
> print(x)
> x = x+1
> print(x)
>
> 1
> 2
> >>> print(x)
> 0
>
> Previous code doesn't generate any
28 matches
Mail list logo