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

[BUG] Vendoring of modules in exampleSite produces invalid modules.txt #798

Open
markdumay opened this issue Feb 24, 2024 · 2 comments
Open
Labels
bug Something isn't working

Comments

@markdumay
Copy link
Collaborator

Describe the bug

Vendoring the modules of Hinode's example site creates an invalid module list.

To reproduce

Steps to reproduce the behavior:

git clone https://github.com/gethinode/hinode.git
cd hinode/exampleSite
hugo mod vendor
hugo server

Log file

Error: command error: failed to load modules: invalid modules list: "[...]/hinode/exampleSite/_vendor/modules.txt"

Host environment

Hugo environment

hugo v0.123.3-a75a659f6fc0cb3a52b2b2ba666a81f79a459376+extended darwin/arm64 BuildDate=2024-02-23T17:09:20Z VendorInfo=brew
GOOS="darwin"
GOARCH="arm64"
GOVERSION="go1.22.0"
github.com/sass/libsass="3.6.5"
github.com/webmproject/libwebp="v1.3.2"
github.com/sass/dart-sass/protocol="2.5.0"
github.com/sass/dart-sass/compiler="1.71.1"
github.com/sass/dart-sass/implementation="1.71.1"

Additional context

The exampleSite/_vendor/modules.txt file contains the following content:

# github.com/gethinode/hinode
# github.com/gethinode/mod-bootstrap v1.2.2
# github.com/twbs/bootstrap v5.3.2+incompatible
# github.com/gethinode/mod-flexsearch v1.9.0
# github.com/nextapps-de/flexsearch v0.0.0-20240110101704-4c3966709f85
# github.com/gethinode/mod-fontawesome v1.8.1
# github.com/gethinode/mod-utils/v2 v2.1.1
# github.com/gethinode/mod-katex v1.0.5
# github.com/gethinode/mod-leaflet v1.0.0
# github.com/gethinode/mod-lottie v1.4.3
# github.com/airbnb/lottie-web v5.12.2+incompatible

Adding a version to the first line seems to solve the issue, e.g.:

# github.com/gethinode/hinode v0.0.0
[...]

The problem is likely related to PR #786 and #769. It is unclear if this is a configuration error, or an upstream error with Hugo. @deining, maybe you have some additional thoughts?

@markdumay markdumay added the bug Something isn't working label Feb 24, 2024
@deining
Copy link
Contributor

deining commented Feb 26, 2024

It is unclear if this is a configuration error, or an upstream error with Hugo.

This is an upstream error with hugo. I filed an issue for it.

@markdumay
Copy link
Collaborator Author

Ok, thanks for investigating this! It appears that manually adding any version info solves the issue. I guess Hugo is unable to determine the correct version because of the local path substitution (as configured in the workspace file).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants