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

[BUG] Cannot click on "Open in Colab" badges #196

Closed
2 tasks done
leonlan opened this issue Jun 23, 2024 · 4 comments
Closed
2 tasks done

[BUG] Cannot click on "Open in Colab" badges #196

leonlan opened this issue Jun 23, 2024 · 4 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@leonlan
Copy link
Contributor

leonlan commented Jun 23, 2024

Describe the bug

I cannot click on "Open in Colab" badge in examples that are displayed in the documentation.

To Reproduce

System info

N/A

Additional context

I was trying to see how you implemented Colab notebooks for your examples and then I noticed this behavior :-).

Reason and Possible fixes

Instead of using HTML hyperlinks like this:

"<a href=\"https://colab.research.google.com/github/ai4co/rl4co/blob/main/examples/2-full-training.ipynb\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"></a>\n"

I think it will work when you use Markdown-style rendering like this:

[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/ai4co/rl4co/blob/main/examples/2-full-training.ipynb)

That works for me when notebooks are rendered using nbsphinx. Not 100% sure though if this also fixes this issue.

Checklist

  • I have checked that there is no similar issue in the repo (required)
  • I have provided a minimal working example to reproduce the bug (required)
@leonlan leonlan added the bug Something isn't working label Jun 23, 2024
@fedebotu fedebotu added this to the 0.5.0 milestone Jul 3, 2024
@fedebotu
Copy link
Member

fedebotu commented Jul 3, 2024

Thanks @leonlan for reporting! We noticed this as well before, it seems to be a problem with the compilation of Jupyter notebooks that "flatten" those buttons 🤔

We are planning to go through the docs before the 0.5.0, possibly changing the template to something a better than the PyTorch Lightning docs one (maybe trying to copy-paste from your PyVRP ;) ). Similarly let's switch the main installer to poetry @cbhua , it is long due 🤣

@fedebotu
Copy link
Member

Latest version of the documentation is out!

https://rl4co.readthedocs.io/en/latest/

The Colab badge seems to work fine now ~

@leonlan
Copy link
Contributor Author

leonlan commented Jul 25, 2024

docs looking good :-)

@fedebotu
Copy link
Member

We imitated quite a bit PyVRP's style ;)
(But we did in MkDocs which turned out to be... quite a bit harder than expected 🤣 )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants