diff --git a/README.rst b/README.rst index 10e9bb3..c8506af 100644 --- a/README.rst +++ b/README.rst @@ -22,7 +22,7 @@ limitations: 2. For filesystem-based modules (which is 99% of them) Python's importer only understands one loader type per directory. It's not possible to store code or data written in something other than Python in the same - directory with Python module code and load it via ``import``. + directory with Python module code and load both via ``import``. The former requires a certain degree of abstraction and thought. For the latter, most people ignore the problem and load module configuration @@ -37,7 +37,7 @@ What's the real problem? The real problem is that Python's traditional extensions, ``.py``, ``.pyc/.pyo``, and ``.so/.dll`` files, are hard-coded in Python. In -Python 2, they're in the ``imp`` builtin; In Python 3, they're defined +Python 2, they're in the ``_imp`` builtin; In Python 3, they're defined in a private section of `importlib`. Either way, they're not accessible for modification and extension. diff --git a/docs/_sources/details.txt b/docs/_sources/details.txt index fc64dd2..b5e8692 100644 --- a/docs/_sources/details.txt +++ b/docs/_sources/details.txt @@ -108,4 +108,5 @@ path where you believe Python modules can be found, and list through them. This facility is useful for large frameworks where a user wants to add new commands, or new objects, or new operations; Django uses this facility a lot! The ``pkgutil`` library depends upon Finders being able -to iterate their contents. +to iterate their contents, and with the filesystem iterator, that means +being able to tell there's more than one kind of syntax in a directory. diff --git a/docs/_sources/eli5.txt b/docs/_sources/eli5.txt index 667777f..2bfa0f4 100644 --- a/docs/_sources/eli5.txt +++ b/docs/_sources/eli5.txt @@ -1,6 +1,20 @@ ELI5: Explain Like I'm Five! ============================ +.. _eli5-metapaths: + +Meta Paths +========== + +TODO + +.. _eli5-pathhooks: + +Path Hooks +========== + +TODO + .. _eli5-finders: Finders @@ -15,23 +29,16 @@ Loaders TODO -.. _eli5-pathhooks: - -Path Hooks -========== - -TODO - -.. _eli5-metapaths: - -Meta Paths -========== - -TODO - .. _eli5-specs: Module Specifications ===================== TODO + +.. _eli5-iterate-modules: + +Pkgutil Iterate Modules +======================= + +TODO diff --git a/docs/details.html b/docs/details.html index bb80d05..423aa0a 100644 --- a/docs/details.html +++ b/docs/details.html @@ -142,7 +142,8 @@ path where you believe Python modules can be found, and list through them. This facility is useful for large frameworks where a user wants to add new commands, or new objects, or new operations; Django uses this facility a lot! The pkgutil library depends upon Finders being able -to iterate their contents.
+to iterate their contents, and with the filesystem iterator, that means +being able to tell there’s more than one kind of syntax in a directory. diff --git a/docs/doctrees/details.doctree b/docs/doctrees/details.doctree index 3f156c3..b8afd71 100644 Binary files a/docs/doctrees/details.doctree and b/docs/doctrees/details.doctree differ diff --git a/docs/doctrees/eli5.doctree b/docs/doctrees/eli5.doctree index 3ae8b0e..63f9b68 100644 Binary files a/docs/doctrees/eli5.doctree and b/docs/doctrees/eli5.doctree differ diff --git a/docs/doctrees/environment.pickle b/docs/doctrees/environment.pickle index 8585243..412b7bc 100644 Binary files a/docs/doctrees/environment.pickle and b/docs/doctrees/environment.pickle differ diff --git a/docs/doctrees/history.doctree b/docs/doctrees/history.doctree index e6bd5f7..0d835e7 100644 Binary files a/docs/doctrees/history.doctree and b/docs/doctrees/history.doctree differ diff --git a/docs/doctrees/index.doctree b/docs/doctrees/index.doctree index 91e894c..ea1d07c 100644 Binary files a/docs/doctrees/index.doctree and b/docs/doctrees/index.doctree differ diff --git a/docs/doctrees/polyloader.doctree b/docs/doctrees/polyloader.doctree index c93a229..17439f9 100644 Binary files a/docs/doctrees/polyloader.doctree and b/docs/doctrees/polyloader.doctree differ diff --git a/docs/doctrees/readme.doctree b/docs/doctrees/readme.doctree index 886ef46..3d3b28b 100644 Binary files a/docs/doctrees/readme.doctree and b/docs/doctrees/readme.doctree differ diff --git a/docs/doctrees/todo.doctree b/docs/doctrees/todo.doctree index b9c622d..2bafad4 100644 Binary files a/docs/doctrees/todo.doctree and b/docs/doctrees/todo.doctree differ diff --git a/docs/doctrees/usage.doctree b/docs/doctrees/usage.doctree index befda84..bb99cca 100644 Binary files a/docs/doctrees/usage.doctree and b/docs/doctrees/usage.doctree differ diff --git a/docs/eli5.html b/docs/eli5.html index 3b2a380..15c768d 100644 --- a/docs/eli5.html +++ b/docs/eli5.html @@ -47,6 +47,14 @@TODO
+TODO
+TODO
-TODO
-TODO
+TODO
The former requires a certain degree of abstraction and thought. For the latter, most people ignore the problem and load module configuration @@ -86,7 +86,7 @@ Hy or Coconut in a framework like Django, Flask or Glitch.
The real problem is that Python’s traditional extensions, .py, .pyc/.pyo, and .so/.dll files, are hard-coded in Python. In -Python 2, they’re in the imp builtin; In Python 3, they’re defined +Python 2, they’re in the _imp builtin; In Python 3, they’re defined in a private section of importlib. Either way, they’re not accessible for modification and extension.
This problem is made harder by the pkglib module, which is part of diff --git a/docs/searchindex.js b/docs/searchindex.js index 495186d..2c80bdd 100644 --- a/docs/searchindex.js +++ b/docs/searchindex.js @@ -1 +1 @@ -Search.setIndex({envversion:42,terms:{load:[9,5],all:[9,5],code:[9,5],just:[7,5],move:5,multilingu:9,syntax:[7,9],veri:9,through:[1,5],abil:5,follow:7,discoveri:9,annoyingli:9,find:[9,5],languag:9,suffix:[8,10],access:[9,5],onli:[9,5],depend:5,execut:[9,5],smart_str:5,flask:9,point:5,had:[9,5],except:[9,5],than:9,resort:5,add:[7,5],program:[9,5],those:9,appli:5,reason:5,sens:5,folder:5,main:7,app:7,match:5,take:5,real:0,fly:5,them:[9,5],sourc:0,"return":5,string:[9,5],thei:[9,5],get:9,handl:[9,5],initi:5,util:5,framework:[9,5],ast_compil:7,mechan:[9,10],fall:9,front:9,now:[7,5],archiv:5,requir:9,name:5,tri:5,term:9,like:5,specif:5,hook:5,edit:7,anyth:5,list:[9,5],iter:5,method:5,"try":5,collect:5,either:[9,1],each:[9,5],did:5,unicod:5,page:0,mean:[9,5],compil:[7,8,10],everyth:[7,5],been:9,set:10,natur:5,hard:9,resourc:5,assumpt:5,see:5,meta:5,bare:5,stabl:0,download:1,http:1,fullnam:5,todo:4,hamper:9,librari:[7,9,5],out:[9,5],variabl:[9,5],index:0,insid:5,goe:5,unready_str:5,someth:9,abl:5,per:9,dll:9,current:[9,10,5],figur:[9,5],leav:[10,5],limit:9,content:[0,2,5],"public":1,metadata:5,altern:5,elfsternberg:1,elimin:9,object:[9,5],run:[9,10,1,5],extend:9,web:5,importerror:5,inspect:9,usag:0,privat:9,standard:[9,10],extens:9,job:5,base:[9,5],modif:9,believ:[9,5],repositori:1,found:5,releas:0,from:[0,5],process:[1,5],modifi:5,problem:0,interpret:9,importlib:9,about:5,last:[9,10,5],would:5,befor:5,freedom:5,could:[9,5],success:5,manag:[7,9,10],turn:9,degre:9,instanc:10,context:10,constructor:5,databas:5,typic:5,view:7,com:1,first:[9,5],oper:5,via:9,user:5,finder:5,directli:9,extra:5,win:9,arrai:5,independ:5,encod:5,pkglib:9,automat:10,loader:5,mochi:7,glitch:9,api:5,yaml:9,latter:9,instal:0,guid:1,facil:5,your:[7,1],git:1,ready_str:5,pkgutil:5,wai:[9,5],script:7,top:7,scan:5,two:[9,5],"long":9,github:1,avail:5,start:5,json:9,handler:5,master:1,statement:[9,5],time:[0,5],call:5,type:9,until:5,store:[9,5],more:[9,5],"function":[9,5],setup:1,lot:5,offer:5,termin:1,peopl:9,copi:1,back:9,remot:5,part:[9,5],understand:9,translat:5,scope:[10,5],line:7,former:9,written:[7,9,5],reset:8,made:[9,5],word:9,describ:5,possibl:9,launcher:7,remov:10,work:[7,5],harder:9,intern:[9,5],can:[7,9,1,5],easier:5,defin:9,"__init__":5,minimum:5,compile_fil:7,whatev:9,assum:10,report:9,modul:5,find_modul:5,heart:9,coconut:9,featur:9,constant:5,file:[9,5],creat:10,give:5,almost:5,certain:9,"abstract":9,filenam:5,ani:5,activ:10,packag:2,pip:1,hy_compil:7,have:[7,9,1,5],tarbal:1,synopsi:0,curl:1,sai:0,getmoduleinfo:9,alwai:9,develop:[9,5],want:[7,9,5],thing:9,make:5,expos:9,when:[9,5],same:9,write:[7,9,5],funni:5,builtin:9,other:9,read:5,split:5,which:[9,10,5],subdirectori:5,command:[9,1,5],you:[7,9,1,5],mochi_compil:7,enabl:9,even:5,imp:9,recogn:9,again:9,configur:9,clone:1,after:9,upon:[10,5],solut:0,most:9,larg:5,plan:7,pyo:9,pair:10,construct:9,pyc:9,data:9,"class":[9,5],tradit:9,repo:1,lifetim:10,don:1,whose:5,filesystem:[9,5],anywher:5,well:7,fine:9,django:[7,9,5],thought:9,heterogen:9,exampl:7,ignor:9,thi:[0,1,5],english:0,onc:1,model:[7,5],section:9,dot:[9,5],usual:9},objtypes:{"0":"py:module","1":"py:function"},objnames:{"0":["py","module","Python module"],"1":["py","function","Python function"]},filenames:["index","installation","modules","contributing","eli5","details","authors","usage","polyloader","readme","todo","history"],titles:["Welcome to polyloader","Installation","polyloader","<no title>","ELI5: Explain Like I’m Five!","Details on Import and Polyloader","<no title>","Usage","polyloader package","Synopsis","<no title>","<no title>"],objects:{"":{polyloader:[8,0,0,"-"]},polyloader:{reset:[8,1,1,""],install:[8,1,1,""]}},titleterms:{sai:9,old:5,modul:[4,8],meta_path:5,system:5,hook:4,meta:4,tabl:0,stabl:1,still:5,what:[9,5],from:1,welcom:[0,5],explain:4,solut:9,detail:5,content:8,how:5,between:5,"new":5,instal:1,finder:4,real:9,sourc:1,synopsi:9,python:5,english:9,usag:7,differ:5,eli5:[4,5],path_hook:5,indic:0,"import":5,releas:1,path:[4,5],loader:4,look:5,search:5,like:4,specif:4,packag:8,directori:5,doe:5,matter:5,polyload:[0,2,5,8],thi:9,time:9,five:4,problem:9,where:5,know:5}}) \ No newline at end of file +Search.setIndex({envversion:42,terms:{load:[9,5],all:[9,5],code:[9,5],just:[7,5],move:5,multilingu:9,syntax:[7,9,5],veri:9,through:[1,5],abil:5,follow:7,discoveri:9,annoyingli:9,find:[9,5],languag:9,suffix:[8,10],access:[9,5],onli:[9,5],depend:5,execut:[9,5],smart_str:5,flask:9,point:5,had:[9,5],except:[9,5],than:[9,5],resort:5,add:[7,5],program:[9,5],those:9,appli:5,reason:5,sens:5,folder:5,main:7,app:7,match:5,take:5,real:0,fly:5,them:[9,5],sourc:0,"return":5,string:[9,5],thei:[9,5],get:9,handl:[9,5],initi:5,util:5,framework:[9,5],ast_compil:7,mechan:[9,10],fall:9,front:9,now:[7,5],archiv:5,requir:9,name:5,tri:5,term:9,like:5,specif:5,hook:5,edit:7,anyth:5,list:[9,5],iter:5,method:5,"try":5,collect:5,either:[9,1],each:[9,5],did:5,unicod:5,page:0,mean:[9,5],compil:[7,8,10],everyth:[7,5],been:9,set:10,natur:5,hard:9,resourc:5,assumpt:5,see:5,meta:5,bare:5,stabl:0,download:1,http:1,fullnam:5,todo:4,hamper:9,librari:[7,9,5],out:[9,5],variabl:[9,5],index:0,insid:5,goe:5,unready_str:5,someth:9,"_imp":9,abl:5,per:9,dll:9,current:[9,10,5],figur:[9,5],leav:[10,5],limit:9,content:[0,2,5],"public":1,metadata:5,altern:5,elfsternberg:1,elimin:9,object:[9,5],run:[9,10,1,5],extend:9,web:5,importerror:5,inspect:9,usag:0,privat:9,standard:[9,10],extens:9,job:5,base:[9,5],modif:9,believ:[9,5],repositori:1,found:5,releas:0,from:[0,5],process:[1,5],modifi:5,problem:0,interpret:9,importlib:9,both:9,about:5,last:[9,10,5],would:5,befor:5,freedom:5,could:[9,5],success:5,manag:[7,9,10],turn:9,degre:9,instanc:10,context:10,constructor:5,databas:5,typic:5,view:7,com:1,first:[9,5],oper:5,via:9,user:5,finder:5,directli:9,extra:5,win:9,arrai:5,independ:5,encod:5,pkglib:9,automat:10,loader:5,mochi:7,glitch:9,api:5,yaml:9,latter:9,instal:0,guid:1,facil:5,your:[7,1],git:1,ready_str:5,pkgutil:5,wai:[9,5],script:7,top:7,scan:5,two:[9,5],"long":9,github:1,avail:5,start:5,json:9,handler:5,master:1,statement:[9,5],time:[0,5],call:5,type:9,tell:5,store:[9,5],more:[9,5],"function":[9,5],setup:1,lot:5,offer:5,termin:1,peopl:9,copi:1,back:9,remot:5,part:[9,5],understand:9,translat:5,scope:[10,5],line:7,former:9,written:[7,9,5],reset:8,kind:5,made:[9,5],word:9,describ:5,possibl:9,launcher:7,remov:10,work:[7,5],harder:9,intern:[9,5],can:[7,9,1,5],until:5,defin:9,easier:5,minimum:5,compile_fil:7,whatev:9,assum:10,report:9,modul:5,find_modul:5,heart:9,coconut:9,featur:9,constant:5,file:[9,5],creat:10,give:5,almost:5,certain:9,"abstract":9,filenam:5,ani:5,activ:10,"__init__":5,packag:2,pip:1,hy_compil:7,have:[7,9,1,5],tarbal:1,synopsi:0,curl:1,sai:0,getmoduleinfo:9,alwai:9,develop:[9,5],want:[7,9,5],thing:9,make:5,expos:9,when:[9,5],same:9,write:[7,9,5],funni:5,builtin:9,other:9,read:5,split:5,which:[9,10,5],subdirectori:5,command:[9,1,5],you:[7,9,1,5],mochi_compil:7,enabl:9,even:5,recogn:9,again:9,configur:9,clone:1,after:9,upon:[10,5],solut:0,most:9,larg:5,plan:7,pyo:9,pair:10,construct:9,pyc:9,data:9,"class":[9,5],tradit:9,repo:1,lifetim:10,don:1,whose:5,filesystem:[9,5],anywher:5,well:7,fine:9,django:[7,9,5],thought:9,heterogen:9,exampl:7,ignor:9,thi:[0,1,5],english:0,onc:1,model:[7,5],section:9,dot:[9,5],usual:9},objtypes:{"0":"py:module","1":"py:function"},objnames:{"0":["py","module","Python module"],"1":["py","function","Python function"]},filenames:["index","installation","modules","contributing","eli5","details","authors","usage","polyloader","readme","todo","history"],titles:["Welcome to polyloader","Installation","polyloader","<no title>","ELI5: Explain Like I’m Five!","Details on Import and Polyloader","<no title>","Usage","polyloader package","Synopsis","<no title>","<no title>"],objects:{"":{polyloader:[8,0,0,"-"]},polyloader:{reset:[8,1,1,""],install:[8,1,1,""]}},titleterms:{sai:9,old:5,look:5,modul:[4,8],meta_path:5,system:5,hook:4,meta:4,tabl:0,stabl:1,still:5,what:[9,5],from:1,pkgutil:4,explain:4,solut:9,detail:5,content:8,how:5,between:5,"new":5,instal:1,finder:4,real:9,sourc:1,synopsi:9,python:5,english:9,usag:7,differ:5,eli5:[4,5],path_hook:5,indic:0,"import":5,releas:1,path:[4,5],loader:4,welcom:[0,5],search:5,like:4,specif:4,packag:8,directori:5,iter:4,doe:5,matter:5,polyload:[0,2,5,8],thi:9,time:9,five:4,problem:9,where:5,know:5}}) \ No newline at end of file diff --git a/docs/src/details.rst b/docs/src/details.rst index fc64dd2..b5e8692 100644 --- a/docs/src/details.rst +++ b/docs/src/details.rst @@ -108,4 +108,5 @@ path where you believe Python modules can be found, and list through them. This facility is useful for large frameworks where a user wants to add new commands, or new objects, or new operations; Django uses this facility a lot! The ``pkgutil`` library depends upon Finders being able -to iterate their contents. +to iterate their contents, and with the filesystem iterator, that means +being able to tell there's more than one kind of syntax in a directory. diff --git a/docs/src/eli5.rst b/docs/src/eli5.rst index 667777f..2bfa0f4 100644 --- a/docs/src/eli5.rst +++ b/docs/src/eli5.rst @@ -1,6 +1,20 @@ ELI5: Explain Like I'm Five! ============================ +.. _eli5-metapaths: + +Meta Paths +========== + +TODO + +.. _eli5-pathhooks: + +Path Hooks +========== + +TODO + .. _eli5-finders: Finders @@ -15,23 +29,16 @@ Loaders TODO -.. _eli5-pathhooks: - -Path Hooks -========== - -TODO - -.. _eli5-metapaths: - -Meta Paths -========== - -TODO - .. _eli5-specs: Module Specifications ===================== TODO + +.. _eli5-iterate-modules: + +Pkgutil Iterate Modules +======================= + +TODO