insiders 4.19.0 container fails to build with `Config value: 'plugins'. Error: The "git-revision-date-localized" plugin is not installed` error
hellt opened this issue · comments
Contribution guidelines
- I've read the contribution guidelines and wholeheartedly agree
I've found a bug and checked that ...
- ... the problem doesn't occur with the
mkdocs
orreadthedocs
themes - ... the problem persists when all overrides are removed, i.e.
custom_dir
,extra_javascript
andextra_css
- ... the documentation does not mention anything about my problem
- ... there are no open or closed issues that are related to my problem
Description
Automated pipeline for building insiders container fail with Config value: 'plugins'. Error: The "git-revision-date-localized" plugin is not installed
for 4.19.0 version.
Previous versions do not have this isssue
Expected behaviour
build succeeds
Actual behaviour
build fails
Steps to reproduce
- start building container image using pipelines from insiders repo
Package versions
NA
Configuration
NA
System information
NA
Thanks for reporting. However, the plugin is optional, so it shouldn't fail. Authors should add the plugin themselves before building the container. Could you please provide a minimum reproducible example? Are you just building your fork or did you make changes?
Ah wait. I think I know where this is coming from – the "checking" is done against our mkdocs.yml
file, which defines the plugin. Since it is not installed, the check is not successful and the build fails. I see how we can exempt the plugin.
I am following insiders installation manual and building a container out of unmodified insiders repo as I am using containerized mkdocs material package to build docs (not pip-based build)
My expectation was that the container that gets build in this job should have the necessary plugins for mkdocs-material to work (I do not see why it is useful to exclude some plugins, tbh).
Up till 4.19.0 it was working fine for me
In general, we want to keep the image as small as possible. However, we can certainly add the following plugins, as they're now supported by Material for MkDocs Insiders and I expect an increasing number of people to be using them:
mkdocs-git-committers-plugin
mkdocs-git-revision-date-localized
Fixed in squidfunk/mkdocs-material-insiders@1b25b3c1c59f0cc7032d5776ff88d8234859ba87 and released as part of 8.3.8+insiders-4.19.1
@squidfunk there is that issue with git security and gh actions that results in a build failure
it can be fixed if you change the docker run
command that test the build as follows
# before
docker run --rm -i -v ${PWD}:/docs ${{ github.event.repository.full_name }} build
# after
docker run -v ${PWD}:/docs --entrypoint ash ${{ github.event.repository.full_name }} -c 'git config --global --add safe.directory /docs; mkdocs build'
ref: https://github.com/srl-labs/learn-srlinux/blob/main/.github/workflows/cicd.yml#L70
created a PR for insiders - https://github.com/squidfunk/mkdocs-material-insiders/pull/39