henriklovhaug / md-tui

Markdown renderer in the terminal
GNU Affero General Public License v3.0
205 stars 13 forks source link

Cannot find value `HIGHLIGHT_QUERY` in crate `tree_sitter_go` #148

Closed Vrajs16 closed 2 months ago

Vrajs16 commented 2 months ago

When installing this, I am facing this issue:

error[E0425]: cannot find value `HIGHLIGHT_QUERY` in crate `tree_sitter_go`
  --> index.crates.io-6f17d22bba15001f/md-tui-0.8.4/src/highlight/go.rs:11:69
   |
11 |         HighlightConfiguration::new(language, "go", tree_sitter_go::HIGHLIGHT_QUERY, "", "")
   |                                                                     ^^^^^^^^^^^^^^^
   |
tree-sitter-go-0.21.2/bindings/rust/lib.rs:44:1
   |
44 | pub const HIGHLIGHTS_QUERY: &str = include_str!("../../queries/highlights.scm");
   | -------------------------------- similarly named constant `HIGHLIGHTS_QUERY` defined here
   |
help: a constant with a similar name exists
   |
11 |         HighlightConfiguration::new(language, "go", tree_sitter_go::HIGHLIGHTS_QUERY, "", "")
   |                                                                     ~~~~~~~~~~~~~~~~
help: consider importing one of these constants
   |
1  + use tree_sitter_bash::HIGHLIGHT_QUERY;
   |
1  + use tree_sitter_c::HIGHLIGHT_QUERY;
   |
1  + use tree_sitter_cpp::HIGHLIGHT_QUERY;
   |
1  + use tree_sitter_javascript::HIGHLIGHT_QUERY;
   |
help: if you import `HIGHLIGHT_QUERY`, refer to it directly
   |
11 -         HighlightConfiguration::new(language, "go", tree_sitter_go::HIGHLIGHT_QUERY, "", "")
11 +         HighlightConfiguration::new(language, "go", HIGHLIGHT_QUERY, "", "")
   |

Looking at the latest PR which was merged, I see some changes reflected which is causing this issue

henriklovhaug commented 2 months ago

Does it happen if you install using --locked as well?

Vrajs16 commented 2 months ago

Hi @henriklovhaug, I was able to install it with --locked. If this is not an issue you can close. Thank you 🙂

henriklovhaug commented 2 months ago

Nice