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 #1449 , but has dependency on mkdocs 1.6 #1460

Closed
wants to merge 1 commit into from

Conversation

mi-hol
Copy link
Contributor

@mi-hol mi-hol commented Feb 2, 2025

the script command sections consist of only 2 characters (i.e. >D), hence with default search setting they will not be reported as hits. See https://www.mkdocs.org/user-guide/configuration/#min_search_length

the script command sections consist of only 2 characters (i.e. >D), hence with default setting they will not be reported as hits.
See https://www.mkdocs.org/user-guide/configuration/#min_search_length
@mi-hol
Copy link
Contributor Author

mi-hol commented Feb 2, 2025

it seems mkdocs needs to be upgraded to 1.6 for this setting to work.

https://github.com/tasmota/docs/blob/master/requirements.txt currently specifies 1.5.3

Who could test the update as a prerequisite to my PR?

@mi-hol mi-hol changed the title fix #1449 fix #1449 , but has dependency on mkdocs 1.6 Feb 2, 2025
@mi-hol
Copy link
Contributor Author

mi-hol commented Feb 2, 2025

upgrading is described in https://www.mkdocs.org/about/release-notes/

@Staars
Copy link
Collaborator

Staars commented Feb 2, 2025

I did some quick local tests and did not encounter problems with the newest version.
Let's see ...

@Staars
Copy link
Collaborator

Staars commented Feb 2, 2025

It must be another problem as mkdocs 1.6.1 was already used anyway according to the GH action log:

Collecting mkdocs>=1.5.3,~=1.5 (from -r requirements.txt (line 2))
  Downloading mkdocs-1.6.1-py3-none-any.whl.metadata (6.0 kB)

Did you check successfully with a local installation?

@mi-hol
Copy link
Contributor Author

mi-hol commented Feb 2, 2025

Did you check successfully with a local installation?

No, I'm only used to update docs in projects that use GH Actions to validate all changes.
The result is a temporary site that can be used to verify changes manually too.
From my perspective this approach is much more reliable because of all sort of issues in local installations due to version differences & conflicts.

@mi-hol
Copy link
Contributor Author

mi-hol commented Feb 2, 2025

could the issue be caused by mkdocs-material and its search component Lunr.js?
This search has likely different options & severe issues as desribed in https://squidfunk.github.io/mkdocs-material/blog/2024/08/19/how-were-transforming-material-for-mkdocs/#search-and-discovery

  Downloading mkdocs-1.6.1-py3-none-any.whl.metadata (6.0 kB)
Collecting mkdocs-material>=9.4.0 (from -r requirements.txt (line 3))
  Downloading mkdocs_material-9.6.1-py3-none-any.whl.metadata (19 kB)
Collecting mkdocs-material-extensions~=1.3 (from -r requirements.txt (line 4))
  Downloading mkdocs_material_extensions-1.3.1-py3-none-any.whl.metadata (6.9 kB)

@Staars
Copy link
Collaborator

Staars commented Feb 2, 2025

Yes, could be.
If you would have checked your PR with a local build, you would have seen an error like that:

mkdocs build --strict
WARNING -  Config value 'plugins': Plugin 'material/search' option 'min_search_length': Unsupported option

Aborted with 1 configuration warnings in 'strict' mode!

You see that the search plugin from mkdocs-material is referred here, which does not seem to have the option min_search_length .
Hence my suggestion to test such things locally first and not pushing untested things upstream.

Maybe someone with more knowledge about MkDocs can enlighten us.

@mi-hol
Copy link
Contributor Author

mi-hol commented Feb 2, 2025

Hence my suggestion to test such things locally first and not pushing untested things upstream.

well my goal is NOT to understand all internals of mkdocs, it just appeared to be an easy fix to an annoying issue in doc search.
As we know now its unfortunately not that simple :(

@mi-hol mi-hol closed this Feb 2, 2025
@mi-hol
Copy link
Contributor Author

mi-hol commented Feb 3, 2025

@Staars @arendst maybe switching to theme "Read the Docs" would resolve the severe issues mention by theme "material" developers
and would lower the hurdle to documentation updates significantly!
At the same time quality of doc updates would increase via Automatic deploy previews
image

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.

2 participants