Dash API Docsets for Pythonista and Editorial?
-
I've tried to run doc2dash on a mirror of the docs for Pythonista and Editorial, but it seems that script requires access to the source documentation to be built correctly. Is there any chance this can be done? It'd be much easier to read the documentation if it were available this way. Any help is greatly appreciated. Thanks!
-
I'll see if there's something I can do to make it work. Otherwise, it'd have to be up to those with access to the source code for both apps to create it.
-
@leesavide , I did read about the doc set creation sometime ago. Was interesting, but I think it didn't get my heart racing. Dash on iOS is so disappointing to me compared to Mac OS. No notes, no ability to download stackflow database. It's ok, but just ok....it's a shame, on Mac OS it's a great product, on iOS just another so so reference tool. But still I will not kick,it out of bed if it had the Pythonista doc set ๐
-
@Phuket2 I can agree with you about it being a "meh" app for iOS. But on the other hand: LovelyDocs on Android is even MORE "meh" than that, with no way to even add custom docsets from other sources. Aside from its limitations, there's no other documentation browser I know of for iOS that can be worked with in this way, especially since you could also just strip out the embedded Python, matplotlib, numpy, etc. docs in Pythonista's documentation, given that Dash already has those available as separate docsets... Unless there's specific changes to the versions that Pythonista uses.
-
@leesavide , but I would alove a copy of the docs if you do get them done. Are you on the beta or 1.5? The beta you get access to the source. I think but am not sure , it maybe hidden away in a folder on 1.5 also. I am not sure why you need the source of dash though. Again, I haven't had time to go back and review the dash doc building requirements.
I think I will write to the authors and ask them if they have plans to add more of the Mac app features. The thing I am missing the most on iOS is a nice database knowledge base style app. I want to store things like links to stackflow/other website answers to specific things I have looked up, code snippets(not just for pasting), but little pieces of code I see around that look really nice, but I know I will forget we're I seen it and how it was done) storing the syntax for adding Dropbox pictures into forum here (just get these mental blanks sometimes) so a system I guess that just supports tagging and is able store various types of media intelligently. I have just started using NoteSuite, it seems pretty good, but still a notes system rather than a knowledge base system. If you have any recommendations, would love to hear them
-
The Dash docs mention a process for converting an HTML doc tree into Dash. https://github.com/cclauss/Ten-lines-or-less/blob/master/pythonista_docs.py shows you how to get to the Pythonista HTML docs embedded in the app (works in the Beta but not sure if it works on 1.5). Or you could take the HTML doc tree starting at http://omz-software.com/pythonista/docs/index.html for the Pythonista v1.5 docs.
There are some differences between the Python Standard Lib docs and the embedded version. For instance, check out the docs for the
webbrowser
module.
-
This post is deleted!last edited by
-
@Phuket2 I am not currently on the beta. As for being able to access the source code, I actually would only need access to the documentation; I don't really need access to the source code at all. If the project has a branch specifically for the documentation, I'd only need access to that alone. And I agree about Dash being able to have snippets support, its not that much to ask for.
@ccc I do know about the HTML doc tree method for Dash API docs, but unfortunately it's also a long process of ensuring that all the links in every file lead to a location relative to the resources within the docset itself, which is something I'm not able to do just yet, mainly due to my schedule. :x I knew there were changes to the standard Python libraries so iOS architecture could use them, I just figured it could just be easier to make an errata of differences between documentation sets, rather than reinvent the wheel. :)
-
@leesavide , as I say, I am not passionate about it. So I also don't want to spend too much time on it. But in the next few days I will look into again. I remember when I looked into before, it just looked to hard for me. But I wil look with new eyes ๐
I did run @ccc code, but it was sitting there forever to return a result. Internet here is crap today. I am guessing that was the reason
-
As soon as someone figures this out please share.
-
I have been only following this thread peripherally, but you guys know that the Documentation folder ( a few up from the pylib that contains the built in scripts) has the genindex files, and also a sphinx sources folder(which has .txt files of the docs)? Is that what you are looking for?
>>> os.listdir(os.path.join(os.path.split(os.__file__)[0],'../../../Documentation')) ['.buildinfo', '_images', '_sources', '_static', 'about.html', 'bugs.html', 'completion_index.json', 'contents.html', 'copyright.html', 'download.html', 'faq', 'genindex-A.html', 'genindex-B.html', 'genindex-C.html', 'genindex-D.html', 'genindex-E.html', 'genindex-F.html', 'genindex-G.html', 'genindex-H.html', 'genindex-I.html', 'genindex-J.html', 'genindex-K.html', 'genindex-L.html', 'genindex-M.html', 'genindex-N.html', 'genindex-O.html', 'genindex-P.html', 'genindex-Q.html', 'genindex-R.html', 'genindex-S.html', 'genindex-Symbols.html', 'genindex-T.html', 'genindex-U.html', 'genindex-V.html', 'genindex-W.html', 'genindex-X.html', 'genindex-Y.html', 'genindex-Z.html', 'genindex-_.html', 'genindex-all.html', 'genindex.html', 'glossary.html', 'howto', 'index.html', 'ios', 'library', 'license.html', 'matplotlib', 'numpy', 'objects.inv', 'objects_min.inv', 'objects_py.inv', 'py-modindex.html', 'reference', 'search.html', 'searchindex.js', 'sympy', 'tutorial', 'whatsnew'] >>> os.listdir(os.path.join(os.path.split(os.__file__)[0],'../../../Documentation/_sources')) ['about.txt', 'bugs.txt', 'contents.txt', 'copyright.txt', 'faq', 'glossary.txt', 'howto', 'ios', 'library', 'license.txt', 'reference', 'tutorial', 'whatsnew']
-
This post is deleted!last edited by
-
โ(___โ) I kinda feel dumb now. Just copy the IPA file and unzip it to a folder, look for the doc sources there. Then cd to it and run the doc2dash command as you see fit.
I had forgotten I did the same thing when I wanted to recreate the ePubs to all the O'Reilly Media ebook apps, when they were available.
-
@leesavide , Lol. Does that mean you can do it?
-
@Phuket2 Yes, I'll do it as soon as I'm able to.
-
@leesavide , ok perfect. I understand you have time constraints. I thought your comment was saying that you could. Was just checking. But good we have a conversation about it. Amazing the things that can come out a a simple conversation
-
I've tried this a while ago because I thought it would be nice to offer downloadable DocSets for Dash. As far as I remember, it didn't work completely because of the way I combine the Pythonista "core" documentation, and the ones for NumPy/matplotlib/SymPy.
I had some trouble combining them into one Sphinx project (don't remember the details), so I wrote a script that builds them separately, and combines the indexes I need for the in-app search afterwards.
Apparently, this confuses the docset2dash tool, and the result only contained the "core" docs, and not NumPy/matplotlib/SymPy โ which may actually not be such a big problem because I think separate docsets are available for these packages.
-
@omz That make sense - doc2dash isn't a recursive tool. I kind of figured itd have to be a scripted job to generate a Dash docset, I just didn't know if it was already being done or not.
-
@omz it seems both of us may be wrong: I ran the tool today and was given all of the documentation. NumPy, Matplotlib, and SymPy were added along with them; I did not need to rerun the tool on any additional subproject. I do not know if it worked; I will have to determine that when I'm able to get on my Mac. I did notice that the SQLite3 database took longer than normal to generate, and I did happen to run the script on Editorial's documentation earlier, but I'll have to test that later, as well.
-
GOOD NEWS
I got the docsets to work and they do include all the documentation of their respective subprojects, and any custom documentation, for both Editorial and Pythonista.
BAD NEWS
I don't know how to make the docsets start on the index.html page. (ยดโโฝโ `) They both seem to want to start on the modules index page instead. If anyone can tell me how to fix that, I'd be more than willing to post the files on a GitHub Pages site, given I have @omz's permission to.
-
Sure, go ahead. Don't know how to fix the index.html issue, and I don't think it would bother me much โ I mostly just use Dash for searching anyway.