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

Upper case letters in path causing match to fail #7686

Open
rhyst opened this issue Sep 14, 2020 · 11 comments
Open

Upper case letters in path causing match to fail #7686

rhyst opened this issue Sep 14, 2020 · 11 comments

Comments

@rhyst
Copy link

rhyst commented Sep 14, 2020

What version of Hugo are you using (hugo version)?

$ hugo version
Hugo Static Site Generator v0.74.3-DA0437B4/extended linux/amd64 BuildDate: 2020-07-23T16:30:30Z

Does this issue reproduce with the latest release?

yes

Probably easiest to read jmoorings comment on the forum:
https://discourse.gohugo.io/t/upper-case-letters-in-path-causing-match-to-fail/28069

Basically there seems to be an issue when matching folder names that have upper case letters in. jmooring suggests it is because case normalisation is being done on the pattern, rather than on the directory path.

@kc0bfv
Copy link

kc0bfv commented Mar 21, 2021

I accidentally duped this bug (as jmooring noticed) - but it still happened 29 days ago on the most recent hugo back then:

hugo v0.81.0-59D15C97 linux/amd64 BuildDate=2021-02-19T17:07:12Z VendorInfo=gohugoio

@rodrigoalcarazdelaosa
Copy link

I accidentally duped this bug (as jmooring noticed) - but it still happened 29 days ago on the most recent hugo back then:

hugo v0.81.0-59D15C97 linux/amd64 BuildDate=2021-02-19T17:07:12Z VendorInfo=gohugoio

Still suffering this bug in the latest Hugo version:

hugo v0.83.1-5AFE0A57+extended linux/amd64 BuildDate=2021-05-02T14:38:05Z VendorInfo=gohugoio

@github-actions
Copy link

github-actions bot commented Jun 2, 2022

This issue has been automatically marked as stale because it has not had recent activity. The resources of the Hugo team are limited, and so we are asking for your help.
If this is a bug and you can still reproduce this error on the master branch, please reply with all of the information you have about it in order to keep the issue open.
If this is a feature request, and you feel that it is still relevant and valuable, please tell us why.
This issue will automatically be closed in the near future if no further activity occurs. Thank you for all your contributions.

@github-actions github-actions bot added the Stale label Jun 2, 2022
@jmooring
Copy link
Member

jmooring commented Jun 2, 2022

Still reproducible with v0.100.1

MRE

git clone --single-branch -b hugo-github-issue-7686 https://github.com/jmooring/hugo-testing hugo-github-issue-7686
cd hugo-github-issue-7686
hugo server

@jmooring
Copy link
Member

@satotake This is still failing with 281554e. Is that expected?

git clone --single-branch -b hugo-github-issue-7686 https://github.com/jmooring/hugo-testing hugo-github-issue-7686
cd hugo-github-issue-7686
hugo server

@satotake
Copy link
Contributor

My motivation of 281554e was from my own situation and I have never seen this issue. Not sure whether expected or not at the moment.
Anyway I will take a look at this tomorrow. @jmooring

@bep
Copy link
Member

bep commented Sep 23, 2022

@jmooring have you tested it with ... Hugo 0.104.0?

@jmooring
Copy link
Member

have you tested it with ... Hugo 0.104.0?

Yes, still fails.

@bep
Copy link
Member

bep commented Sep 23, 2022

Yes, still fails.

That is certainly odd, oh well.

What I wish for my next life is that every OS implemented a file system with forward slashes and filenames limited to lower case ascii.

@satotake
Copy link
Contributor

satotake commented Sep 24, 2022

#10305 did not consider case-unmatched patterns.
So I had no expectation of {{ with resources.GetMatch "images/abc/*" }} for assets/images/ABC/kitten.jpg (though I have found that we should cover the case now.)

However, it is unexpected that {{ with resources.GetMatch "images/ABC/*" }} does not match the image.

Seemingly, we need more test and fixations.
Thanks for pointing out, @jmooring

satotake added a commit to satotake/hugo that referenced this issue Sep 24, 2022
- add integration tests
- fix not found error in `walk.go`

Fix gohugoio#7686
Fix gohugoio#10112

- ref
  - gohugoio#10305
  - gohugoio@281554e
satotake added a commit to satotake/hugo that referenced this issue Sep 24, 2022
- add integration tests
- fix not found error in `walk.go`

Fix gohugoio#7686
Fix gohugoio#10112

- ref
  - gohugoio#10305
  - gohugoio@281554e
satotake added a commit to satotake/hugo that referenced this issue Sep 24, 2022
- add integration tests
- fix not found error in `walk.go`

Fix gohugoio#7686
Fix gohugoio#10112

- ref
  - gohugoio#10305
  - gohugoio@281554e
satotake added a commit to satotake/hugo that referenced this issue Sep 24, 2022
- add integration tests
- fix not found error in `walk.go`

Fix gohugoio#7686
Fix gohugoio#10112

- ref
  - gohugoio#10305
  - gohugoio@281554e
satotake added a commit to satotake/hugo that referenced this issue Sep 25, 2022
- add integration tests
- use canonical path for glog
- fix cache key for resources

Fix gohugoio#7686
Fix gohugoio#10112

- ref
  - gohugoio#10305
  - gohugoio@281554e
@bep bep added the OnHold label Sep 26, 2022
@kc0bfv
Copy link

kc0bfv commented Oct 11, 2022 via email

@bep bep modified the milestones: v0.131.0, v0.133.0 Aug 9, 2024
@bep bep modified the milestones: v0.133.0, Unscheduled Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants