Skip to content

should update CSS to reflect new docutils 0.17 HTML5 tags #9001

Closed

Description

@drammock

The HTML5 writer in docutils 0.17 writes the .. sidebar:: directive as the HTML5 aside tag (used to be div). This means that the rule in basic.css_t for styling those elements no longer applies, since the rule is written for div.sidebar instead of aside.sidebar:

div.sidebar {
margin: 0 0 0.5em 1em;
border: 1px solid #ddb;
padding: 7px;
background-color: #ffe;
width: 40%;
float: right;
clear: right;
overflow-x: auto;
}

According to the docutils changelog linked above, other tags now being output are main, section, header, footer, figure, and figcaption. I haven't systematically checked for where / whether similar CSS mismatches are happening as a result, but I'd guess there are a few more besides the div -> aside issue that I ran into.

EDIT: crossref to mne-tools/mne-python#9031 where there are screenshots of a sidebar directive that is failing to get styled properly.

Activity

  1. added this to the 4.0.0 milestone on Mar 15, 2021
  2. Daltz333 commented on Apr 4, 2021

    @Daltz333

    A ping on this. docutils 0.17 has just gotten published and now breaks generation

  3. mgeier commented on Apr 4, 2021

    @mgeier
    Contributor

    I've just created #9059, which hopefully fixes this issue.

    @drammock

    According to the docutils changelog linked above, other tags now being output are main, section, header, footer, figure, and figcaption. I haven't systematically checked for where / whether similar CSS mismatches are happening as a result, but I'd guess there are a few more besides the div -> aside issue that I ran into.

    If you find more errors, can you please create a new issue?

  4. ericholscher commented on Apr 5, 2021

    @ericholscher
    Contributor

    Another option for now is just to pin to docutils <0.17. We did this on the RTD theme, until we have a chance to fully test and implement the changes.

  5. modified the milestones: 4.0.0, 3.5.4 on Apr 7, 2021
  6. return42 commented on Apr 8, 2021

    @return42

    Another option for now is just to pin to docutils <0.17

    Another option I would vote for is to maintain a own fork and decouple docutils development from David Goodger: Each minor release brings new incompatibilities, each release of docutils cause problems in hundred of projects.

  7. tk0miya commented on Apr 8, 2021

    @tk0miya
    Member

    I feel such a reaction is very hysteric and intolerant. If you'd like to get the docutils project better, please join the project and help them. (or please vote to decouple Sphinx development from me also)

  8. tk0miya commented on Apr 8, 2021

    @tk0miya
    Member

    I merged #9059 to 3.5.x branch. So closing this now. Please file another issue if you find other troubles. Thanks,

  9. return42 commented on Apr 8, 2021

    @return42

    I feel such a reaction is very hysteric and intolerant.

    Apologies my inappropriate comment .. but I'm annoyed that each minor release from docutils caused a cascade of problems.

    If you'd like to get the docutils project better, please join the project

    I had a look years ago ...the access to become team member is unusually difficult .. and personally I have a problem with sourceforge. / I know of some developers who would like to contribute to the project but don't, because the project management is a little bit idiosyncratic.

  10. ericholscher commented on Apr 8, 2021

    @ericholscher
    Contributor

    I think the main goal here is more testing and communication, which is something everyone in the community can help and contribute to. Wearing my Read the Docs hat, we'd love to be able to work with sphinx & docutils to increase testing beta & development across the ecosystem, so hopefully we can catch some of these issues prior to them getting released.

    We can talk more about it over at #9056 perhaps, instead of this old issue, but I think there's some productive work to be done here.

  11. andredias commented on Apr 23, 2021

    @andredias

    Disclaimer: I'm the author of rst2html5

    I'd like to suggest using it instead of docutils' rst2html5. It has been stable for years and produces better results than docutils. Please, see its README.

  12. added a commit that references this issue on May 21, 2021
  13. locked as resolved and limited conversation to collaborators on Jul 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions