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

Fix duplicate names of Pylint Messages in docs #5744

Merged

Conversation

DanielNoord
Copy link
Collaborator

  • Add yourself to CONTRIBUTORS if you are a new contributor.
  • Write a good description on what the PR does.

Type of Changes

Type
βœ“ πŸ› Bug fix
βœ“ πŸ“œ Docs

Description

Pretty stupid to have missed this. Should be merged asap to help SEO.

Closes #5740.

@DanielNoord DanielNoord added the High priority Issue with more than 10 reactions label Jan 29, 2022
@DanielNoord DanielNoord added this to the 2.13.0 milestone Jan 29, 2022
@coveralls
Copy link

coveralls commented Jan 29, 2022

Pull Request Test Coverage Report for Build 1808554416

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 2 unchanged lines in 1 file lost coverage.
  • Overall coverage decreased (-0.01%) to 93.923%

Files with Coverage Reduction New Missed Lines %
pylint/lint/parallel.py 2 92.86%
Totals Coverage Status
Change from base Build 1806840834: -0.01%
Covered Lines: 14852
Relevant Lines: 15813

πŸ’› - Coveralls

@DanielNoord
Copy link
Collaborator Author

@Pierre-Sassoulas What are the titles of the pages in the side bar for you? For me the seconde title doesn't seem to be updated..

@Pierre-Sassoulas
Copy link
Member

For me the second title doesn't seem to be updated.

Same here. It's strange, although it would work as it is it look like there's no page containing "Overview" in the generated code : https://pylint--5744.org.readthedocs.build/en/5744/search.html?q=Overview

@DanielNoord
Copy link
Collaborator Author

Hmm, I'll have a look at this later.

Copy link
Member

@Pierre-Sassoulas Pierre-Sassoulas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe a bug in readthedoc for this MR ? We can merge anyway as "pylint messages" makes sense for Overview of all Pylint messages ?

@DanielNoord
Copy link
Collaborator Author

Maybe a bug in readthedoc for this MR ? We can merge anyway as "pylint messages" makes sense for Overview of all Pylint messages ?

That would be strange.. I'd say let's wait to find the cause of the issue before merging.

@DanielNoord
Copy link
Collaborator Author

Fixed. Stupid mistake... The page was actually auto-generated, so changing the title in the file does nothing πŸ˜“

@Pierre-Sassoulas
Copy link
Member

Pierre-Sassoulas commented Jan 29, 2022

The page was actually auto-generated,

Should we had warning as comment at the beginning of the file ? Or maybe check that the file is up to date.

@DanielNoord
Copy link
Collaborator Author

I don't think we should check for it being up to date, that would mean every change to a message would add changes to the file. Which would inflate commit sizes unnecessarily. I'll add a comment though!

@Pierre-Sassoulas
Copy link
Member

Pierre-Sassoulas commented Jan 29, 2022

I don't think we should check for it being up to date,

Could you add a release stage in tbump to make sure it's up to date at release time then ? (See https://github.com/PyCQA/pylint/blob/main/tbump.toml#L31)

@DanielNoord
Copy link
Collaborator Author

I don't think we should check for it being up to date,

Could you add a release stage in tbump to make sure it's up to date at release time then ?

Do we want it to be? (I have no experience with tbump so no idea how to implement this).

@Pierre-Sassoulas
Copy link
Member

Do we want it to be?

I think it's better if it's not too far from the current state of the code. Another positive things is that the diff is a nice summary of what message appeared between two releases.

I have no experience with tbumb

I made the change myself let me know what you think.

Copy link
Collaborator Author

@DanielNoord DanielNoord left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense! Thanks for your help!

@@ -122,7 +122,10 @@ def _write_messages_list_page(
stream.write(
f""".. _messages-list:

{get_rst_title("Pylint Messages", "=")}
.. NOTE: This file is auto-generated. Make any changes to the associated
.. docs extension in '{__name__}.py'.
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Smart!

@DanielNoord
Copy link
Collaborator Author

Build is failing though :( Do you see what's wrong?

@Pierre-Sassoulas
Copy link
Member

Build is failing though

Hurgh, sorry it was working locally. It sounds like the problem is doc/messages/messages_introduction.rst:15: WARNING: Failed to create a cross reference. A title or caption not found: messages-list I dont know what I changed the broke that. I'm going to check that tomorrow.

@DanielNoord
Copy link
Collaborator Author

@Pierre-Sassoulas Have you had the time to look at this? We should probably try and merge this soon. I can also take a look?

@Pierre-Sassoulas
Copy link
Member

I have no idea right now, and I have a busy week.

What I tried :

  • tox -e docs (work perfectly locally)
  • trying to launch manually (also works)
  • Changing the comment syntax near the reference (did not work)

What I thought about doing next:

  • Bisection of the change in github actions to see what is causing the problem exactly (but it's not elegant)

Ideas welcomed :)

@Pierre-Sassoulas
Copy link
Member

Damn, it was this 'simple' in the end. Thank you for the debug work @DanielNoord, I'm under the water right now and appreciate that.

@Pierre-Sassoulas Pierre-Sassoulas merged commit 533e6b8 into pylint-dev:main Feb 7, 2022
@DanielNoord DanielNoord deleted the messages-duplicate-names branch February 7, 2022 22:40
@DanielNoord
Copy link
Collaborator Author

Same, this was an easy fix I could do in between jobs πŸ˜„

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation πŸ“— High priority Issue with more than 10 reactions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicated title in pylint's message documentation
3 participants