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

Files with same name but different extensions leads to unexpected behaviour #7324

Closed
chrisjsewell opened this issue Mar 17, 2020 · 0 comments
Labels
Milestone

Comments

@chrisjsewell
Copy link
Member

chrisjsewell commented Mar 17, 2020

Describe the bug

If there are multiple files with the same name but different file extensions;
sphinx will silently choose only one to parse:

To Reproduce
Steps to reproduce the behavior:

Given I have an extension installed to parse md

with:

index.rst
a.md
a.rst

index.rst:

.. toctree::
    a.md

This will actually include a.rst in the document, not a.md

Expected behavior
A clear and concise description of what you expected to happen.

Ideally you would have a config option to specify the order of preference for file extensions,
or if not set, a warning would be logged.

Your project
Link to your sphinx project, or attach zipped small project sample.

First noted in:
executablebooks/MyST-NB#82 (comment)

Screenshots
If applicable, add screenshots to help explain your problem.

Environment info

  • OS: Mac
  • Python version: 3.7.6
  • Sphinx version: 2.4.4
  • Sphinx extensions: myst-parser

Additional context
Add any other context about the problem here.

  • [e.g. URL or Ticket]
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants