-
Notifications
You must be signed in to change notification settings - Fork 7
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
Documentation page build action using Sphinx #14
Conversation
This is the page on my GitHub: https://slobentanzer.github.io/sctk/index.html |
|
As an executable, i.e. colab? I think if you do not want to host that yourself, would have to be a link rather than embedded. But a tutorials page with links to the notebooks is easy.
Not sure, I am not a Sphinx wizard. But we can definitely find that out.
I think they use the |
Yeah, the notebook as a static render. Exactly as the current GitHub link does, but within the docs. I specify |
Look at that, it did the thing. It's marginally annoying that it's in two tables but it kind of reflects on the fact the GMM is a utility function, I guess. I'm having no luck trying to get the notebook to show up. I moved the |
If you want folks to use the gaussian utility function, why not put it in the |
As stated before, its behaviour can be controlled via the Hopefully you'll have better luck with that damned notebook than I did. I tried adding a title cell and everything. |
What about just linking it from a regular markdown page ("example notebooks" or "tutorials")? Could be an adequate short-term solution. |
Can you help me with the nbsphinx in the toml file? I have no idea what the hell to do it to clear the automated builds, I thought |
Not sure what you mean, in poetry you don't have to specify versions. I never worked with that either, and I rarely work with notebooks. Do you have a working example of how you want it to look? |
My query has nothing to do with the notebook part. It has everything to do with the cursed toml and lock and I don't know what. Building is failing and I have no idea why. Help. |
I tried adding just the line Literally all I've done is added Please help :( |
Keep calm and read the docs. :) Have you removed your venv and lock file and installed from scratch yet? For me it builds without problems with nbsphinx. |
It says right there in the error:
-> remove lock file |
You've always had it, and made small incremental changes to it, so it felt like it was not my place to remove it. But if you say so. |
The lock file is not that important, you can simply regenerate it by running poetry install. It is good for reproducibility, but in development it is expendable. |
Thanks for the help. The docs have rendered sensibly online now. If you have opinions about nbsphinx's version, feel free to change it. If you have opinions that the lock file should return, feel free to reintroduce it. Should there be a badge about the docs? |
Thanks, looks great indeed. Gonna use this for my other repositories from now on. :)
I did not actually mean to completely remove it at all, but rather temporarily, just to fix the issue. It is good practise to provide it in case someone wants to reproduce that exact version. I'll add it back. |
Sure thing. I think this just about does it! Minimal changes left to the readme, linking some stuff and whatnot. Do I need to change anything in the docs configs or will they spawn at https://teichlab.github.io/sctk/ automatically? Do you know how to tell the poetry TOML to render the readme on the pip page, and have links to stuff? I know how to do it in flit, which I'm not sure is that useful here |
Turns out the readme and various links can be easily accomplished: https://python-poetry.org/docs/pyproject/ I can sort it out on my end once you're happy with how things are here and I merge? |
You need to set up what is described in the PR description above.
Do you mean pypi.org? It just uses your GitHub readme AFAIK. But maybe that is done by Poetry, IDK. It always just worked for me. |
Is this mergeable? I presume I may have queries about the page setup once merged. |
True dat, you could add some classifiers and the docs homepage. Do you want to create a separate file for the pypi readme?
I am good. :) Remember to replace the docs building badge location, I used my fork again for testing. |
and yes |
Perfect, thanks. Check it out, we're live! https://teichlab.github.io/sctk/ I'll make some minimal tweaks to the readme and the toml and then up on pip it goes. Thanks a lot for all your help with this stuff. |
Very happy to help in open source! I also learned some new things. :) |
The new workflow uses sphinx on a GitHub action runner to create html documentation, including an API reference generated from the docstrings, and pushes it to the
gh-pages
branch.To deploy the webpage, the repository needs to be configured for hosting a gh-pages website in the settings ("Pages" > from branch).