Skip to content

Conversation

@StaticRocket
Copy link
Member

@StaticRocket StaticRocket commented May 9, 2025

  • chore: move to exclude only logic based on toc.txt

    Exclude all documents with an rst suffix not explicitly listed in the toc.txt.
    This removes a lot of dead logic and unnecessary config values.

    For a while this project mixed including and excluding document logic, where
    the include list was provided as an exhaustive description of everything
    through the toc.txt and a basic exclude list was provided as a sparse array
    populated manually in the OS tags.py file.

    This sparse array was supposed to change the way we searched for index files
    (previously referred to as toctreefiles), but ultimately any index files we
    needed were already listed in the main toc.txt.

    Signed-off-by: Randolph Sapp [email protected]

Closes #167

@StaticRocket
Copy link
Member Author

I've tested this change locally against all DEVFAMILY and OS combinations. It resulted in no difference.

@StaticRocket
Copy link
Member Author

The next logical change will be another PR, where I remove that string concatenation to add the file extension back in and manipulate all the TOC files to include extensions.

@cshilwant
Copy link
Member

+ @jsuhaas22 @jeevantelukula @sadik-smd for reviews

jeevantelukula
jeevantelukula previously approved these changes May 13, 2025
@jeevantelukula
Copy link
Collaborator

jeevantelukula commented May 13, 2025

@StaticRocket
WARNING: toctree contains reference to nonexisting document 'linux/Overview_Software_Stack' [toc.not_readable]

Getting these warnings when referencing all toc trees. Hope these will be taken care in your follow up PR

@StaticRocket
Copy link
Member Author

StaticRocket commented May 13, 2025

That's expected. It's reducing the logic but moving a chunk of the previously suppressed toc.excluded warnings to toc.not_readable.

I suppose that does overload the toc.not_readable warning though, as now it can signify that the file doesn't exist OR it's intentionally ignored. Hmm. Maybe we do want to keep the include+exclude logic so error filtering is a little easier. Let me think about this a bit.

@StaticRocket StaticRocket changed the title chore: move to include only logic chore: move to exclude only logic May 14, 2025
Exclude all documents with an rst suffix not explicitly listed in the
toc.txt. This removes a lot of dead logic and unnecessary config values.

For a while this project mixed including and excluding document logic,
where the include list was provided as an exhaustive description of
everything through the toc.txt and a basic exclude list was provided as
a sparse array populated manually in the OS tags.py file.

This sparse array was supposed to change the way we searched for index
files (previously referred to as toctreefiles), but ultimately any index
files we needed were already listed in the main toc.txt.

Signed-off-by: Randolph Sapp <[email protected]>
@StaticRocket
Copy link
Member Author

Moved to exclude only logic as this preserves the current warning behavior. Slightly updated to clean up more of the old *.py file comments around the old exclude_patterns list.

Copy link
Collaborator

@jeevantelukula jeevantelukula left a comment

Choose a reason for hiding this comment

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

LGTM

@StaticRocket StaticRocket merged commit 6db89fa into TexasInstruments:master May 14, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Automatically populate exclude_patterns

4 participants