Wrong <meta name="generator" content> value in docs
Docs generated via crystal docs have <meta name="generator" content> value from the crystal version used to build the compiler instead of the compiled one, being one-of - ie. docs generated with crystal 0.35.1 have crystal 0.34.0 given and docs build for master have crystal version 0.35.1 given.
The value used by the docs generator is Crystal::VERSION which is the actual version of the compiler, also reported by crystal --version. So that should be correct.
And CI should use the freshly built compiler to build the docs, so it should really be identical to project_version.
In fact, the build_docs job for 0.35.1 docs reports running with Crystal 0.35.1 [5999ae29b] (2020-06-19) (
https://app.circleci.com/pipelines/github/crystal-lang/crystal/3875/workflows/528b3e80-5102-4267-a3f5-1855d3f4b667/jobs/48703). No idea what's going wrong here.
FWIW crystal --version seems to be using Crystal::Config.version which reads the VERSION file directly while Crystal::VERSION is a built in constant based on that value. So might be some issue with using a built in constant within the compiler itself? Could maybe just replace this tag with Crystal::Config.version and call it a day?
I don’t understand why this is an issue. I think the doc generator works as expected. It makes sense to me that the generator version matches with the version of the compiler performing the doc generation.
It makes sense to me that the generator version matches with the version of the compiler performing the doc generation.
@potomak it doesn't, that's the issue.
@Sija wouldn’t you expect to see docs with a generator version value equals to the value of ‘crystal -v’? I think that’s reasonable.
Maybe the issue is that the doc isn’t generated using the latest compiler build rather than what value is used in the template.
@potomak I'd expect that the generator version put in the <meta/> would contain the value of the compiler version used to generate the docs.
Where is the definition of the job that generates the docs?