Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Garbage generation (1.4.2 - Mac OS 10.9.5 - Python 2.7.5) #166

Closed
paschembri opened this issue Nov 12, 2014 · 0 comments
Closed

Garbage generation (1.4.2 - Mac OS 10.9.5 - Python 2.7.5) #166

paschembri opened this issue Nov 12, 2014 · 0 comments

Comments

@paschembri
Copy link

The use of the local["xyz"] seems to generate uncollectable garbage. I tried the following :

>>> from plumbum import local
>>> ls = local['ls']
>>> ls['-l']()
...
>>> del ls
>>> import gc
>>> gc.collect()
10
>>> gc.garbage
[<subprocess.Popen object at 0x10b459790>]

Then I tried just with subprocess :

>>> import subprocess
>>> subprocess.check_output(['ls', '-l'])
...
>>> import gc
>>> gc.collect()
0
>>> gc.garbage
[]

I also tried with

>>> ls.run('-l')

and it also generates garbage.

I'll look into it ; could you confirm that you have the same behavior ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant