Keats / tera

A template engine for Rust based on Jinja2/Django
http://keats.github.io/tera/
MIT License
3.36k stars 280 forks source link

Build problem with 1.20.0 #925

Closed fxwiegand closed 1 month ago

fxwiegand commented 1 month ago

There seems to be an issue with the build of 1.20.0:

   Compiling tera v1.20.0
error[E0599]: no method named `len` found for struct `Pairs` in the current scope
Error:     --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tera-1.20.0/src/parser/mod.rs:1049:46
     |
1049 |     let mut nodes = Vec::with_capacity(pairs.len());
     |                                              ^^^
     |
help: there is a method `le` with a similar name, but with different arguments
    --> /rustc/129f3b9964af4d4a709d1383930ade12dfe7c081/library/core/src/iter/traits/iterator.rs:3887:5

For more information about this error, try `rustc --explain E0599`.
error: could not compile `tera` (lib) due to 1 previous error

This happens on our dependabot PR that wants to update tera.

fxwiegand commented 1 month ago

Solved with updating other crates.

hubcio commented 2 weeks ago

@fxwiegand do you mind tell me how did you fix it?

EDIT: nevermind, I just did cargo update and it looks like everything works fine.

fxwiegand commented 2 weeks ago

Yep that also did the trick for me.