{"id":"101f7ff24183731b","repo":"gohugoio/hugo","slug":"errfeaturenotavailable","errorCode":"ErrFeatureNotAvailable","errorMessage":"this feature is not available in your current Hugo version, see https://goo.gl/YMrWcn for more information","messagePattern":"this feature is not available in your current Hugo version, see https://goo\\.gl/YMrWcn for more information","errorType":"exception","errorClass":"FeatureNotAvailableError","httpStatus":null,"severity":"error","filePath":"common/herrors/errors.go","lineNumber":87,"sourceCode":"\nfunc (e *errMessage) Error() string {\n\treturn e.msg\n}\n\nfunc (e *errMessage) Unwrap() error {\n\treturn e.err\n}\n\n// IsFeatureNotAvailableError returns true if the given error is or contains a FeatureNotAvailableError.\nfunc IsFeatureNotAvailableError(err error) bool {\n\treturn errors.Is(err, &FeatureNotAvailableError{})\n}\n\n// ErrFeatureNotAvailable denotes that a feature is unavailable.\n//\n// We will, at least to begin with, make some Hugo features (SCSS with libsass) optional,\n// and this error is used to signal those situations.\nvar ErrFeatureNotAvailable = &FeatureNotAvailableError{Cause: errors.New(\"this feature is not available in your current Hugo version, see https://goo.gl/YMrWcn for more information\")}\n\n// FeatureNotAvailableError is an error type used to signal that a feature is not available.\ntype FeatureNotAvailableError struct {\n\tCause error\n}\n\nfunc (e *FeatureNotAvailableError) Unwrap() error {\n\treturn e.Cause\n}\n\nfunc (e *FeatureNotAvailableError) Error() string {\n\treturn e.Cause.Error()\n}\n\nfunc (e *FeatureNotAvailableError) Is(target error) bool {\n\t_, ok := target.(*FeatureNotAvailableError)\n\treturn ok\n}","sourceCodeStart":69,"sourceCodeEnd":105,"githubUrl":"https://github.com/gohugoio/hugo/blob/8a468df065a75c1c7cf9f6850f32148746590ea5/common/herrors/errors.go#L69-L105","documentation":"ErrFeatureNotAvailable (a FeatureNotAvailableError defined in common/herrors/errors.go:87) signals that a feature exists in Hugo but is not compiled into or supported by the binary you are running. It was introduced for optional build-tag features like SCSS/Sass via libsass, which only the 'extended' Hugo build includes. Callers wrap it so IsFeatureNotAvailableError can detect it and print a helpful message pointing to https://goo.gl/YMrWcn.","triggerScenarios":"Invoking a feature your binary lacks: transforming SCSS/Sass with css.Sass (toSCSS) on a non-extended Hugo build; using WebP or other encoders excluded by build tags; any code path that returns or wraps herrors.ErrFeatureNotAvailable.","commonSituations":"Installing standard Hugo instead of hugo_extended (common with apt, brew formula variants, CI docker images, or Netlify/Vercel default binaries) and then building a theme that uses SCSS; downgrading Hugo and losing a feature the site depends on; running a self-compiled binary without the required build tags (e.g. 'extended').","solutions":["Install the extended edition of Hugo (download hugo_extended from GitHub releases, or 'brew install hugo' which is extended) and verify with 'hugo version' showing '+extended'.","In CI, pin the extended binary (e.g. set HUGO_VERSION and use the extended asset in Netlify/GitHub Actions).","If building from source, compile with the required tag: CGO_ENABLED=1 go install -tags extended github.com/gohugoio/hugo@latest.","Alternatively, switch the site to Dart Sass (hugo mod / installing dart-sass) or drop the SCSS pipeline if you cannot use extended."],"exampleFix":"# before (CI)\nwget https://github.com/gohugoio/hugo/releases/download/v0.148.0/hugo_0.148.0_linux-amd64.tar.gz\n\n# after\nwget https://github.com/gohugoio/hugo/releases/download/v0.148.0/hugo_extended_0.148.0_linux-amd64.tar.gz","handlingStrategy":"type-guard","validationCode":"// Check the running Hugo version supports the feature before using it\nif !hugo.IsAtLeast(\"0.148.0\") { skipFeature() }","typeGuard":"func isFeatureUnavailable(err error) bool {\n    return herrors.IsFeatureNotAvailableError(err) // or errors.Is(err, herrors.ErrFeatureNotAvailable)\n}","tryCatchPattern":"if err := run(); errors.Is(err, herrors.ErrFeatureNotAvailable) {\n    // degrade gracefully or tell the user to upgrade Hugo / use the extended build\n}","preventionTips":["Pin a minimum Hugo version with config `module.hugoVersion.min`","Use the extended/withdeploy Hugo build when features require it","Gate template features with `hugo.IsExtended` / version checks instead of assuming availability"],"tags":["hugo","build","scss","extended-edition","environment"],"analyzedSha":"8a468df065a75c1c7cf9f6850f32148746590ea5","analyzedAt":"2026-07-31T21:23:07.045Z","schemaVersion":2}