Re: Pickle caching objects?

2019-12-01 Thread José María Mateos
On Sun, Dec 01, 2019 at 12:26:15PM +1100, Chris Angelico wrote: I can't answer your question authoritatively, but I can suggest a place to look. Python's memory allocator doesn't always return memory to the system when the objects are freed up, for various reasons including the way that memory

Pickle caching objects?

2019-11-30 Thread José María Mateos
Hi, I just asked this question on the IRC channel but didn't manage to get a response, though some people replied with suggestions that expanded this question a bit. I have a program that has to read some pickle files, perform some operations on them, and then return. The pickle objects I

Re: Random signal capture when using multiprocessing

2019-07-06 Thread José María Mateos
On Sat, Jul 06, 2019 at 04:54:42PM +1000, Chris Angelico wrote: > But if I comment out the signal.signal line, there seem to be no ill > effects. I suspect that what you're seeing here is the multiprocessing > module managing its own subprocesses, telling some of them to shut > down. I added a

Random signal capture when using multiprocessing

2019-07-05 Thread José María Mateos
Hi, This is a minimal proof of concept for something that has been bugging me for a few days: ``` $ cat signal_multiprocessing_poc.py import random import multiprocessing import signal import time def signal_handler(signum, frame): raise Exception(f"Unexpected signal {signum}!") def

Re: send PIL.Image to django server side and get it back

2018-07-19 Thread José María Mateos
On Mon, Jul 16, 2018 at 06:40:45AM -0700, Christos Georgiou - ΤΖΩΤΖΙΟΥ wrote: > You need first to serialize the object to bytes that can go over the > wire. There is no predefined way to do that, so you can: > > >>> import io > >>> file_like_object = io.BytesIO() > >>>

Re: Where's the junk coming from?

2018-06-26 Thread José María Mateos
On Mon, Jun 25, 2018, at 13:37, Mark Lawrence wrote: > More of the flaming things, this time name@1261/38.remove-ij1-this. Any > ideas as I don't understand this stuff? I've contacted the list admin about this. It doesn't seem like it's going to go away on its own. I just received another

Re: Where's the junk coming from?

2018-06-25 Thread José María Mateos
On Sun, Jun 24, 2018 at 09:39:33PM +0100, Mark Lawrence wrote: > Hi folks, > > In the last hour or so I've seen via thunderbird and gmane around 15 > emails from various people where the from field is > name@1261/38.remove-r7u-this. The part after the @ symbol never > changes. I've seen the

Re: a Python bug report

2018-05-29 Thread José María Mateos
On Wed, May 30, 2018 at 01:07:38AM +, Ruifeng Guo wrote: > Hello, > We encountered a bug in Python recently, we checked the behavior for Python > version 2.7.12, and 3.1.1, both version show the same behavior. Please see > below the unexpected behavior in "red text". Have you tried the

Re: Usenet Gateway

2018-05-24 Thread José María Mateos
On Thu, May 24, 2018, at 09:10, Chris Green wrote: > > Yes I can mark an entire thread as "read" in IMAP. > > > A *thread* yes, but not a whole list. I.e. if you read this using > mail/IMAP you can mark a thread read but you can't mark *all* Python > list messages read in one go can you? With

Re: Spam levels.

2018-05-21 Thread José María Mateos
On Mon, May 21, 2018 at 10:00:41AM +0200, m wrote: > I also almost stopped reading c.l.python, because of enormous spam > levels. Do I have any option to read it without spam, other than launch > my own filtering NNTP server and do whack the mole game for myself? > > Maybe join forces and

Re: syntax oddities

2018-05-18 Thread José María Mateos
uldn't dare inline-replying in my current Outlook corporate environment. I just top-post, don't trim, go with the flow. Cheers, -- José María Mateos https://rinzewind.org/blog-es || https://rinzewind.org/blog-en -- https://mail.python.org/mailman/listinfo/python-list

Re: syntax oddities

2018-05-18 Thread José María Mateos
ling list (that of the e-mail client I'm using right now): it is very useful for searches. Every e-mail contains just the right amount of text necessary to be properly read, as opposed to a more or less complete copy of the current thread. Cheers, -- José María Mateos https://rinzewind.org/blog-es

Re: Pandas, create new column if previous column(s) are not in [None, '', np.nan]

2018-04-11 Thread José María Mateos
On Wed, Apr 11, 2018, at 14:48, zljubi...@gmail.com wrote: > I have a dataframe: > [...] This seems to work: df1 = pd.DataFrame( { 'A' : ['a', 'b', '', None, np.nan], 'B' : [None, np.nan, 'a', 'b', '']}) df1['C'] = df1[['A', 'B']].apply(lambda

Re: psutil

2018-02-27 Thread José María Mateos
e? - Is `pip` by any change trying to install a Python 3 package, but you only have the libraries for Python 2 installed? Cheers, -- José María Mateos https://rinzewind.org/blog-es || https://rinzewind.org/blog-en -- https://mail.python.org/mailman/listinfo/python-list