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

Minor inconvenience in tutorials #1885

Closed
cadmus-to opened this issue Aug 26, 2021 · 10 comments · Fixed by #1906
Closed

Minor inconvenience in tutorials #1885

cadmus-to opened this issue Aug 26, 2021 · 10 comments · Fixed by #1906
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@cadmus-to
Copy link

cadmus-to commented Aug 26, 2021

Just want to flag that the action tutorial pages

@christophebedard
Copy link
Member

A simple solution would be to just disable the line numbers. They're probably not needed.

@christophebedard
Copy link
Member

Weirdly enough, when I build the docs locally, it's a bit different. I can't highlight the line numbers and copying using the button doesn't include the line numbers. So maybe this can be fixed.

@cadmus-to
Copy link
Author

Might be better to disable the line numbers to be consistent with other tutorials

@audrow
Copy link
Member

audrow commented Aug 27, 2021

@cadmus-to, thanks for pointing this out. I agree it would be better to make this consistent by disabling line numbers. I'm going to mark this as help wanted. If you want to make a PR, feel free to @ me as a reviewer.

@audrow audrow added help wanted Extra attention is needed good first issue Good for newcomers enhancement New feature or request labels Aug 27, 2021
@clalancette
Copy link
Contributor

This is actually a bug in the Read-the-Docs theme; see readthedocs/sphinx_rtd_theme#1123 (where it has been fixed and merged, but not released yet).

Possible solutions:

  1. Use a prerelease version of the RTD theme.
  2. Downgrade to Sphinx 3.x (which is probably why this works for @christophebedard )
  3. Remove the line numbers from the example completely

The line numbers are an easy way to refer back to code, but I agree that this is inconsistent with the rest of our tutorials. So I'd be fine with just removing that, though a bunch of the text will need to be rewritten to have code inline rather than "see Line 8" or whatever.

@christophebedard
Copy link
Member

christophebedard commented Aug 30, 2021

This is actually a bug in the Read-the-Docs theme; see readthedocs/sphinx_rtd_theme#1123 (where it has been fixed and merged, but not released yet).

Possible solutions:

  1. Use a prerelease version of the RTD theme.
  2. Downgrade to Sphinx 3.x (which is probably why this works for @christophebedard )
  3. Remove the line numbers from the example completely

Yes, I was using Sphinx 3. I did see that issue (and other related ones) and upgraded to Sphinx 4 and then tried a pre-release version of the RTD theme (1.0.0rc1), but it didn't entirely fix the issue. I couldn't select the line numbers (as expected), but copying using the button incorrectly copied the line numbers: executablebooks/sphinx-copybutton#85

@Aut0R3V
Copy link

Aut0R3V commented Sep 5, 2021

Hi is anyone working on this? If not so, I would like to get started on this

@cadmus-to
Copy link
Author

I'm fairly new to git culture, but I don't think anyone is because no PRs have referenced this issue

@Aut0R3V
Copy link

Aut0R3V commented Sep 6, 2021

Sure Thanks!
I just went through the code, and I couldn't understand the underlying problem. If you could please tell me what specifically needs to be changed, I can try that.
Thanks!

@clalancette
Copy link
Contributor

It turns out that this was simpler than I thought; #1906 should fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants