runhide
November 13, 2019, 5:40pm
1
The following code used to work as per the docs :
{{range sort .Params.categories}}
{{.}}
{{end}}
But since I upgraded from v0.55.6 to v0.59.1, I get the error:
error calling sort: sequence must be provided
I’ve tried several different variations, such as
{{range sort .Params.categories "asc"}}
But I can’t get the sort function to work. What am I missing? Thanks.
Did you forgot the value arg?
{{ range sort .Params.tags "value" "desc" }}
runhide
November 13, 2019, 9:10pm
3
I’ve tried doing that as well, but I still get an error.
maiki
November 14, 2019, 1:54am
4
I’m unable to reproduce. Please share a repo that reproduces this error.
2 Likes
runhide
November 15, 2019, 3:49pm
5
Thank you for testing.
I tried the sort function in another project and it works fine so something somewhere is causing an issue in my code. Will troubleshoot and let you folks on here know if I find what’s causing the error.
runhide
November 16, 2019, 2:00pm
6
It took a few hours to figure out, but the reason I’m getting an error when calling sort is because of this pesky little bug .