BUG: GzipFile wrapper objects are not garbage collected (closes ticket #1356).
BUG: GzipFile wrapper objects are not garbage collected (closes ticket #1356).

The underlying problem is that classes monkey-patched via
new.instancemethod will only free memory correctly if they do _not_
implement the __del__ method, which is not the case for gzip.GzipFile.

My proposed solution is to inherit from gzip.GzipFile and override
relevant methods instead of monkey-patching.

pyparallel/numpy,BMJHayward/numpy,BMJHayward/numpy,SiccarPoint/numpy,pelson/numpy,dato-code/numpy,mattip/numpy,naritta/numpy,pelson/numpy,MaPePeR/numpy,bringingheavendown/numpy,ajdawson/numpy,dimasad/numpy,naritta/numpy,Anwesh43/numpy,shoyer/numpy,ewmoore/numpy,MichaelAquilina/numpy,stefanv/numpy,SiccarPoint/numpy,rudimeier/numpy,numpy/numpy,ChristopherHogan/numpy,cowlicks/numpy,stefanv/numpy,seberg/numpy,mingwpy/numpy,yiakwy/numpy,BMJHayward/numpy,b-carter/numpy,mingwpy/numpy,mingwpy/numpy,rmcgibbo/numpy,githubmlai/numpy,ChristopherHogan/numpy,WarrenWeckesser/numpy,pdebuyl/numpy,felipebetancur/numpy,Linkid/numpy,ahaldane/numpy,brandon-rhodes/numpy,larsmans/numpy,tdsmith/numpy,SunghanKim/numpy,MichaelAquilina/numpy,mingwpy/numpy,has2k1/numpy,sonnyhu/numpy,utke1/numpy,jankoslavic/numpy,mwiebe/numpy,Srisai85/numpy,pdebuyl/numpy,skwbc/numpy,madphysicist/numpy,empeeu/numpy,mattip/numpy,solarjoe/numpy,jankoslavic/numpy,kiwifb/numpy,Anwesh43/numpy,anntzer/numpy,jschueller/numpy,ESSS/numpy,groutr/numpy,rgommers/numpy,cjermain/numpy,trankmichael/numpy,felipebetancur/numpy,abalkin/numpy,pbrod/numpy,brandon-rhodes/numpy,numpy/numpy,jonathanunderwood/numpy,WillieMaddox/numpy,charris/numpy,seberg/numpy,Eric89GXL/numpy,shoyer/numpy,anntzer/numpy,ChanderG/numpy,SunghanKim/numpy,maniteja123/numpy,GrimDerp/numpy,endolith/numpy,musically-ut/numpy,rgommers/numpy,GrimDerp/numpy,brandon-rhodes/numpy,MaPePeR/numpy,mindw/numpy,leifdenby/numpy,dato-code/numpy,ajdawson/numpy,ogrisel/numpy,stuarteberg/numpy,gmcastil/numpy,numpy/numpy-refactor,jonathanunderwood/numpy,maniteja123/numpy,GaZ3ll3/numpy,mwiebe/numpy,Dapid/numpy,ESSS/numpy,ahaldane/numpy,rhythmsosad/numpy,matthew-brett/numpy,musically-ut/numpy,skwbc/numpy,GrimDerp/numpy,abalkin/numpy,Anwesh43/numpy,dwf/numpy,NextThought/pypy-numpy,naritta/numpy,maniteja123/numpy,grlee77/numpy,GaZ3ll3/numpy,grlee77/numpy,embray/numpy,GaZ3ll3/numpy,mhvk/numpy,rmcgibbo/numpy,pbrod/numpy,pizzathief/numpy,GaZ3ll3/numpy,NextThought/pypy-numpy,has2k1/numpy,numpy/numpy-refactor,ogrisel/numpy,jankoslavic/numpy,larsmans/numpy,moreati/numpy,CMartelLML/numpy,Srisai85/numpy,stefanv/numpy,mhvk/numpy,nguyentu1602/numpy,musically-ut/numpy,madphysicist/numpy,madphysicist/numpy,jschueller/numpy,WarrenWeckesser/numpy,mindw/numpy,githubmlai/numpy,groutr/numpy,anntzer/numpy,pbrod/numpy,nguyentu1602/numpy,ahaldane/numpy,MichaelAquilina/numpy,empeeu/numpy,jakirkham/numpy,skymanaditya1/numpy,Dapid/numpy,Srisai85/numpy,ChanderG/numpy,Anwesh43/numpy,nguyentu1602/numpy,utke1/numpy,stuarteberg/numpy,ewmoore/numpy,pelson/numpy,abalkin/numpy,BabeNovelty/numpy,chatcannon/numpy,MaPePeR/numpy,MSeifert04/numpy,ddasilva/numpy,solarjoe/numpy,rudimeier/numpy,mindw/numpy,dch312/numpy,ViralLeadership/numpy,bmorris3/numpy,cowlicks/numpy,kirillzhuravlev/numpy,yiakwy/numpy,nguyentu1602/numpy,jakirkham/numpy,mhvk/numpy,kirillzhuravlev/numpy,sinhrks/numpy,behzadnouri/numpy,rmcgibbo/numpy,endolith/numpy,jorisvandenbossche/numpy,Yusa95/numpy,mhvk/numpy,sigma-random/numpy,musically-ut/numpy,mindw/numpy,Eric89GXL/numpy,yiakwy/numpy,pelson/numpy,pbrod/numpy,gmcastil/numpy,mortada/numpy,trankmichael/numpy,embray/numpy,KaelChen/numpy,ViralLeadership/numpy,ViralLeadership/numpy,pyparallel/numpy,bertrand-l/numpy,tdsmith/numpy,pizzathief/numpy,Eric89GXL/numpy,hainm/numpy,Srisai85/numpy,dwillmer/numpy,WarrenWeckesser/numpy,CMartelLML/numpy,KaelChen/numpy,shoyer/numpy,pizzathief/numpy,trankmichael/numpy,embray/numpy,jschueller/numpy,ogrisel/numpy,CMartelLML/numpy,githubmlai/numpy,charris/numpy,cjermain/numpy,dwillmer/numpy,simongibbons/numpy,mortada/numpy,dato-code/numpy,bmorris3/numpy,leifdenby/numpy,ogrisel/numpy,BMJHayward/numpy,sigma-random/numpy,ContinuumIO/numpy,skymanaditya1/numpy,mortada/numpy,argriffing/numpy,jorisvandenbossche/numpy,shoyer/numpy,matthew-brett/numpy,ewmoore/numpy,jankoslavic/numpy,ajdawson/numpy,ekalosak/numpy,ContinuumIO/numpy,dch312/numpy,stuarteberg/numpy,has2k1/numpy,simongibbons/numpy,joferkington/numpy,anntzer/numpy,jakirkham/numpy,pdebuyl/numpy,jonathanunderwood/numpy,leifdenby/numpy,bertrand-l/numpy,numpy/numpy,endolith/numpy,behzadnouri/numpy,ChristopherHogan/numpy,Yusa95/numpy,b-carter/numpy,simongibbons/numpy,endolith/numpy,ddasilva/numpy,kiwifb/numpy,sinhrks/numpy,SunghanKim/numpy,jorisvandenbossche/numpy,andsor/numpy,MaPePeR/numpy,MSeifert04/numpy,rajathkumarmp/numpy,mwiebe/numpy,Yusa95/numpy,dwf/numpy,skymanaditya1/numpy,charris/numpy,gmcastil/numpy,brandon-rhodes/numpy,matthew-brett/numpy,groutr/numpy,AustereCuriosity/numpy,Yusa95/numpy,cjermain/numpy,dimasad/numpy,ekalosak/numpy,joferkington/numpy,gfyoung/numpy,yiakwy/numpy,grlee77/numpy,GrimDerp/numpy,pyparallel/numpy,SiccarPoint/numpy,numpy/numpy-refactor,Linkid/numpy,embray/numpy,skymanaditya1/numpy,ChanderG/numpy,andsor/numpy,chatcannon/numpy,ewmoore/numpy,tynn/numpy,argriffing/numpy,jakirkham/numpy,kirillzhuravlev/numpy,madphysicist/numpy,mathdd/numpy,mathdd/numpy,ewmoore/numpy,SunghanKim/numpy,dch312/numpy,matthew-brett/numpy,grlee77/numpy,numpy/numpy-refactor,utke1/numpy,naritta/numpy,sinhrks/numpy,empeeu/numpy,bringingheavendown/numpy,dwf/numpy,joferkington/numpy,bmorris3/numpy,ahaldane/numpy,ChanderG/numpy,AustereCuriosity/numpy,felipebetancur/numpy,WarrenWeckesser/numpy,immerrr/numpy,rudimeier/numpy,tacaswell/numpy,immerrr/numpy,mattip/numpy,ekalosak/numpy,WillieMaddox/numpy,pelson/numpy,rajathkumarmp/numpy,ESSS/numpy,ssanderson/numpy,cowlicks/numpy,rherault-insa/numpy,charris/numpy,jakirkham/numpy,BabeNovelty/numpy,rhythmsosad/numpy,argriffing/numpy,larsmans/numpy,KaelChen/numpy,bmorris3/numpy,nbeaver/numpy,jorisvandenbossche/numpy,andsor/numpy,larsmans/numpy,NextThought/pypy-numpy,pizzathief/numpy,tacaswell/numpy,jschueller/numpy,rhythmsosad/numpy,ddasilva/numpy,behzadnouri/numpy,mhvk/numpy,dato-code/numpy,skwbc/numpy,BabeNovelty/numpy,sinhrks/numpy,solarjoe/numpy,astrofrog/numpy,rudimeier/numpy,bringingheavendown/numpy,mortada/numpy,dwf/numpy,sonnyhu/numpy,Dapid/numpy,rherault-insa/numpy,tdsmith/numpy,tynn/numpy,ContinuumIO/numpy,cjermain/numpy,numpy/numpy-refactor,ogrisel/numpy,dwillmer/numpy,chatcannon/numpy,stuarteberg/numpy,sonnyhu/numpy,madphysicist/numpy,NextThought/pypy-numpy,tdsmith/numpy,chiffa/numpy,grlee77/numpy,dimasad/numpy,andsor/numpy,b-carter/numpy,jorisvandenbossche/numpy,matthew-brett/numpy,tacaswell/numpy,cowlicks/numpy,rherault-insa/numpy,chiffa/numpy,chiffa/numpy,gfyoung/numpy,KaelChen/numpy,bertrand-l/numpy,ahaldane/numpy,simongibbons/numpy,githubmlai/numpy,hainm/numpy,simongibbons/numpy,sonnyhu/numpy,WarrenWeckesser/numpy,rgommers/numpy,seberg/numpy,ssanderson/numpy,joferkington/numpy,Linkid/numpy,has2k1/numpy,MichaelAquilina/numpy,CMartelLML/numpy,rgommers/numpy,nbeaver/numpy,njase/numpy,dwf/numpy,moreati/numpy,rajathkumarmp/numpy,astrofrog/numpy,hainm/numpy,astrofrog/numpy,mathdd/numpy,SiccarPoint/numpy,njase/numpy,pbrod/numpy,tynn/numpy,MSeifert04/numpy,seberg/numpy,astrofrog/numpy,gfyoung/numpy,kiwifb/numpy,pdebuyl/numpy,MSeifert04/numpy,Linkid/numpy,shoyer/numpy,ChristopherHogan/numpy,kirillzhuravlev/numpy,astrofrog/numpy,drasmuss/numpy,mattip/numpy,ssanderson/numpy,empeeu/numpy,drasmuss/numpy,dwillmer/numpy,nbeaver/numpy,WillieMaddox/numpy,stefanv/numpy,rajathkumarmp/numpy,mathdd/numpy,AustereCuriosity/numpy,pizzathief/numpy,BabeNovelty/numpy,ajdawson/numpy,numpy/numpy,immerrr/numpy,trankmichael/numpy,Eric89GXL/numpy,sigma-random/numpy,sigma-random/numpy,dch312/numpy,rmcgibbo/numpy,stefanv/numpy,drasmuss/numpy,felipebetancur/numpy,rhythmsosad/numpy,dimasad/numpy,njase/numpy,MSeifert04/numpy,embray/numpy,ekalosak/numpy,hainm/numpy,immerrr/numpy,moreati/numpy