Skip to content

Fix Hugo version in postsubmit workflow to resolve build errors - #503

Merged
xuezhaojun merged 1 commit into
open-cluster-management-io:mainfrom
xuezhaojun:fix-hugo-version-postsubmit
Jul 24, 2025
Merged

Fix Hugo version in postsubmit workflow to resolve build errors#503
xuezhaojun merged 1 commit into
open-cluster-management-io:mainfrom
xuezhaojun:fix-hugo-version-postsubmit

Conversation

@xuezhaojun

Copy link
Copy Markdown
Member

Problem

The postsubmit GitHub action was failing with the following error:

WARN  Module "open-cluster-management.io/open-cluster-management-io.github.io" is not compatible with this Hugo version: Min 0.146.0 extended
WARN  Module "github.com/google/docsy" is not compatible with this Hugo version: Min 0.146.0 extended
Error: error building site: parse failed: template: _partials/scripts/katex.html:6: function "try" not defined

Root Cause

  • The hugo.yaml configuration file specifies a minimum Hugo version requirement of 0.146.0 extended
  • The postsubmit workflow was using Hugo version 0.125.5
  • The try function used in KaTeX templates is only available in newer Hugo versions

Solution

Update the Hugo version in .github/workflows/postsubmit.yml from 0.125.5 to 0.146.0 to match the minimum version requirement.

Testing

  • ✅ Local build with Hugo v0.147.8 works successfully
  • ✅ The presubmit workflow already uses the correct Hugo version (0.146.0)
  • ✅ No breaking changes expected as this only updates to the minimum required version

Changes

  • Updated Hugo version in postsubmit workflow from 0.125.5 to 0.146.0
  • Maintained extended: true configuration

This fix ensures the postsubmit workflow uses a Hugo version that is compatible with the project's requirements and supports all the template functions being used.


Pull Request opened by Augment Code with guidance from the PR author

Update Hugo version from 0.125.5 to 0.146.0 in postsubmit.yml to match
the minimum version requirement specified in hugo.yaml. This resolves
the build error where the 'try' function was not defined in the older
Hugo version.

Fixes the postsubmit GitHub action build failure.

Signed-off-by: xuezhaojun <zxue@redhat.com>
@openshift-ci
openshift-ci Bot requested review from dhaiducek and qiujian16 July 24, 2025 06:36
@openshift-ci

openshift-ci Bot commented Jul 24, 2025

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: xuezhaojun

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@netlify

netlify Bot commented Jul 24, 2025

Copy link
Copy Markdown

Deploy Preview for open-cluster-management ready!

Name Link
🔨 Latest commit 6e91bbb
🔍 Latest deploy log https://app.netlify.com/projects/open-cluster-management/deploys/6881d458df82aa0008bc9d20
😎 Deploy Preview https://deploy-preview-503--open-cluster-management.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@xuezhaojun
xuezhaojun merged commit 1ec346d into open-cluster-management-io:main Jul 24, 2025
5 of 6 checks passed
@xuezhaojun
xuezhaojun deleted the fix-hugo-version-postsubmit branch July 24, 2025 09:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant