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

can't install latest corset #214

Closed
OlivierBBB opened this issue Jun 25, 2024 · 9 comments · Fixed by #216
Closed

can't install latest corset #214

OlivierBBB opened this issue Jun 25, 2024 · 9 comments · Fixed by #216

Comments

@OlivierBBB
Copy link
Collaborator

We (@letypequividelespoubelles and myself) are unable to install corset anymore.

Below are the versions of rustc and cargo.
image

 cargo install --path . > log
warning: `/Users/olivierbegassat/dev/rust/corset/.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
warning: `/Users/olivierbegassat/dev/rust/corset/./.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
  Installing corset v9.7.12 (/Users/olivierbegassat/dev/rust/corset)
    Updating crates.io index
     Locking 212 packages to latest compatible versions
      Adding base64 v0.13.1 (latest: v0.22.1)
      Adding bitflags v1.3.2 (latest: v2.6.0)
      Adding cached v0.48.1 (latest: v0.51.4)
      Adding generic-array v0.14.7 (latest: v1.0.0)
      Adding hashbrown v0.12.3 (latest: v0.14.5)
      Adding hashbrown v0.13.2 (latest: v0.14.5)
      Adding heck v0.4.1 (latest: v0.5.0)
      Adding hermit-abi v0.1.19 (latest: v0.4.0)
      Adding indexmap v1.9.3 (latest: v2.2.6)
      Adding itertools v0.10.5 (latest: v0.13.0)
      Adding itertools v0.12.1 (latest: v0.13.0)
      Adding linux-raw-sys v0.4.14 (latest: v0.6.4)
      Adding mio v0.8.11 (latest: v1.0.0)
      Adding ratatui v0.26.3 (latest: v0.27.0)
      Adding ron v0.7.1 (latest: v0.8.1)
      Adding sorbus v0.9.0 (latest: v0.12.1)
      Adding syn v1.0.109 (latest: v2.0.68)
      Adding termcolor v1.1.3 (latest: v1.4.1)
      Adding toml v0.5.11 (latest: v0.8.14)
      Adding wasi v0.11.0+wasi-snapshot-preview1 (latest: v0.13.1+wasi-0.2.0)
      Adding windows-core v0.52.0 (latest: v0.57.0)
      Adding windows-sys v0.48.0 (latest: v0.52.0)
      Adding windows-targets v0.48.5 (latest: v0.52.5)
      Adding windows_aarch64_gnullvm v0.48.5 (latest: v0.52.5)
      Adding windows_aarch64_msvc v0.48.5 (latest: v0.52.5)
      Adding windows_i686_gnu v0.48.5 (latest: v0.52.5)
      Adding windows_i686_msvc v0.48.5 (latest: v0.52.5)
      Adding windows_x86_64_gnu v0.48.5 (latest: v0.52.5)
      Adding windows_x86_64_gnullvm v0.48.5 (latest: v0.52.5)
      Adding windows_x86_64_msvc v0.48.5 (latest: v0.52.5)
warning: associated function `new` is never used
  --> tests/models.rs:22:12
   |
18 | impl Model {
   | ---------- associated function in this implementation
...
22 |     pub fn new(
   |            ^^^
   |
   = note: `#[warn(dead_code)]` on by default

warning: function `arrays_1_oracle` is never used
   --> tests/models.rs:194:4
    |
194 | fn arrays_1_oracle(tr: &Trace) -> bool {
    |    ^^^^^^^^^^^^^^^

warning: `corset` (build script) generated 2 warnings
   Compiling corset v9.7.12 (/Users/olivierbegassat/dev/rust/corset)
error[E0308]: mismatched types
    --> src/inspect/widgets/number.rs:24:34
     |
24   |             self.input.set_style(Style::default().fg(Color::LightRed));
     |                        --------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                        |
     |                        arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1629:12
     |
1629 |     pub fn set_style(&mut self, style: Style) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/number.rs:26:17
     |
25   |               self.input.set_block(
     |                          --------- arguments to this method are incorrect
26   | /                 Block::default()
27   | |                     .borders(Borders::ALL)
28   | |                     .title(format!("{} ERROR: {}", &self.title, err)),
     | |_____________________________________________________________________^ expected `ratatui::widgets::block::Block<'_>`, found `ratatui::widgets::Block<'_>`
     |
     = note: `ratatui::widgets::Block<'_>` and `ratatui::widgets::block::Block<'_>` have similar names, but are actually distinct types
note: `ratatui::widgets::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/widgets/block.rs:64:1
     |
64   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
note: `ratatui::widgets::block::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/widgets/block.rs:67:1
     |
67   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1648:12
     |
1648 |     pub fn set_block(&mut self, block: Block<'a>) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/number.rs:31:34
     |
31   |             self.input.set_style(Style::default().fg(Color::LightGreen));
     |                        --------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                        |
     |                        arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1629:12
     |
1629 |     pub fn set_style(&mut self, style: Style) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/number.rs:33:17
     |
32   |               self.input.set_block(
     |                          --------- arguments to this method are incorrect
33   | /                 Block::default()
34   | |                     .borders(Borders::ALL)
35   | |                     .title(self.title.clone()),
     | |______________________________________________^ expected `ratatui::widgets::block::Block<'_>`, found `ratatui::widgets::Block<'_>`
     |
     = note: `ratatui::widgets::Block<'_>` and `ratatui::widgets::block::Block<'_>` have similar names, but are actually distinct types
note: `ratatui::widgets::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/widgets/block.rs:64:1
     |
64   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
note: `ratatui::widgets::block::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/widgets/block.rs:67:1
     |
67   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1648:12
     |
1648 |     pub fn set_block(&mut self, block: Block<'a>) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/number.rs:42:42
     |
42   |         self.input.set_cursor_line_style(Style::default());
     |                    --------------------- ^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                    |
     |                    arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1770:12
     |
1770 |     pub fn set_cursor_line_style(&mut self, style: Style) {
     |            ^^^^^^^^^^^^^^^^^^^^^

error[E0277]: the trait bound `impl ratatui::widgets::Widget + '_: ratatui::widgets::Widget` is not satisfied
  --> src/inspect/widgets/number.rs:46:33
   |
46 |                 f.render_widget(self.input.widget(), target);
   |                   ------------- ^^^^^^^^^^^^^^^^^^^ the trait `ratatui::widgets::Widget` is not implemented for `impl ratatui::widgets::Widget + '_`
   |                   |
   |                   required by a bound introduced by this call
   |
   = help: the following other types implement trait `ratatui::widgets::Widget`:
             &W
             &str
             BarChart<'_>
             Canvas<'_, F>
             Chart<'_>
             Gauge<'_>
             LineGauge<'_>
             List<'_>
           and 10 others
note: required by a bound in `ratatui::Frame::<'_>::render_widget`
  --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/terminal/frame.rs:74:29
   |
74 |     pub fn render_widget<W: Widget>(&mut self, widget: W, area: Rect) {
   |                             ^^^^^^ required by this bound in `Frame::<'_>::render_widget`

error[E0308]: mismatched types
    --> src/inspect/widgets/regexp.rs:32:34
     |
32   |             self.input.set_style(Style::default().fg(Color::LightRed));
     |                        --------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                        |
     |                        arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1629:12
     |
1629 |     pub fn set_style(&mut self, style: Style) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/regexp.rs:34:17
     |
33   |               self.input.set_block(
     |                          --------- arguments to this method are incorrect
34   | /                 Block::default()
35   | |                     .borders(Borders::ALL)
36   | |                     .title(format!("{} ERROR: {}", &self.title, err)),
     | |_____________________________________________________________________^ expected `ratatui::widgets::block::Block<'_>`, found `ratatui::widgets::Block<'_>`
     |
     = note: `ratatui::widgets::Block<'_>` and `ratatui::widgets::block::Block<'_>` have similar names, but are actually distinct types
note: `ratatui::widgets::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/widgets/block.rs:64:1
     |
64   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
note: `ratatui::widgets::block::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/widgets/block.rs:67:1
     |
67   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1648:12
     |
1648 |     pub fn set_block(&mut self, block: Block<'a>) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/regexp.rs:39:34
     |
39   |             self.input.set_style(Style::default().fg(Color::LightGreen));
     |                        --------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                        |
     |                        arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1629:12
     |
1629 |     pub fn set_style(&mut self, style: Style) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/regexp.rs:41:17
     |
40   |               self.input.set_block(
     |                          --------- arguments to this method are incorrect
41   | /                 Block::default()
42   | |                     .borders(Borders::ALL)
43   | |                     .title(self.title.clone()),
     | |______________________________________________^ expected `ratatui::widgets::block::Block<'_>`, found `ratatui::widgets::Block<'_>`
     |
     = note: `ratatui::widgets::Block<'_>` and `ratatui::widgets::block::Block<'_>` have similar names, but are actually distinct types
note: `ratatui::widgets::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/widgets/block.rs:64:1
     |
64   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
note: `ratatui::widgets::block::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/widgets/block.rs:67:1
     |
67   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1648:12
     |
1648 |     pub fn set_block(&mut self, block: Block<'a>) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/regexp.rs:50:42
     |
50   |         self.input.set_cursor_line_style(Style::default());
     |                    --------------------- ^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                    |
     |                    arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1770:12
     |
1770 |     pub fn set_cursor_line_style(&mut self, style: Style) {
     |            ^^^^^^^^^^^^^^^^^^^^^

error[E0277]: the trait bound `impl ratatui::widgets::Widget + '_: ratatui::widgets::Widget` is not satisfied
  --> src/inspect/widgets/regexp.rs:54:33
   |
54 |                 f.render_widget(self.input.widget(), target);
   |                   ------------- ^^^^^^^^^^^^^^^^^^^ the trait `ratatui::widgets::Widget` is not implemented for `impl ratatui::widgets::Widget + '_`
   |                   |
   |                   required by a bound introduced by this call
   |
   = help: the following other types implement trait `ratatui::widgets::Widget`:
             &W
             &str
             BarChart<'_>
             Canvas<'_, F>
             Chart<'_>
             Gauge<'_>
             LineGauge<'_>
             List<'_>
           and 10 others
note: required by a bound in `ratatui::Frame::<'_>::render_widget`
  --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/terminal/frame.rs:74:29
   |
74 |     pub fn render_widget<W: Widget>(&mut self, widget: W, area: Rect) {
   |                             ^^^^^^ required by this bound in `Frame::<'_>::render_widget`

error[E0308]: mismatched types
    --> src/inspect/widgets/scan.rs:38:38
     |
38   |                 self.input.set_style(Style::default().fg(Color::LightRed));
     |                            --------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                            |
     |                            arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1629:12
     |
1629 |     pub fn set_style(&mut self, style: Style) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/scan.rs:40:21
     |
39   |                   self.input.set_block(
     |                              --------- arguments to this method are incorrect
40   | /                     Block::default()
41   | |                         .borders(Borders::ALL)
42   | |                         .title(format!("ERROR: {}", err)),
     | |_________________________________________________________^ expected `ratatui::widgets::block::Block<'_>`, found `ratatui::widgets::Block<'_>`
     |
     = note: `ratatui::widgets::Block<'_>` and `ratatui::widgets::block::Block<'_>` have similar names, but are actually distinct types
note: `ratatui::widgets::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/widgets/block.rs:64:1
     |
64   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
note: `ratatui::widgets::block::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/widgets/block.rs:67:1
     |
67   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1648:12
     |
1648 |     pub fn set_block(&mut self, block: Block<'a>) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/scan.rs:46:38
     |
46   |                 self.input.set_style(Style::default().fg(Color::LightGreen));
     |                            --------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                            |
     |                            arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1629:12
     |
1629 |     pub fn set_style(&mut self, style: Style) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/scan.rs:48:21
     |
47   |                   self.input.set_block(
     |                              --------- arguments to this method are incorrect
48   | /                     Block::default()
49   | |                         .borders(Borders::ALL)
50   | |                         .title(node.to_string()),
     | |________________________________________________^ expected `ratatui::widgets::block::Block<'_>`, found `ratatui::widgets::Block<'_>`
     |
     = note: `ratatui::widgets::Block<'_>` and `ratatui::widgets::block::Block<'_>` have similar names, but are actually distinct types
note: `ratatui::widgets::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/widgets/block.rs:64:1
     |
64   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
note: `ratatui::widgets::block::Block<'_>` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/widgets/block.rs:67:1
     |
67   | pub struct Block<'a> {
     | ^^^^^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1648:12
     |
1648 |     pub fn set_block(&mut self, block: Block<'a>) {
     |            ^^^^^^^^^

error[E0308]: mismatched types
    --> src/inspect/widgets/scan.rs:64:42
     |
64   |         self.input.set_cursor_line_style(Style::default());
     |                    --------------------- ^^^^^^^^^^^^^^^^ expected `ratatui::style::Style`, found a different `ratatui::style::Style`
     |                    |
     |                    arguments to this method are incorrect
     |
     = note: `ratatui::style::Style` and `ratatui::style::Style` have similar names, but are actually distinct types
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1
     |
228  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
     = note: perhaps two different versions of crate `ratatui` are being used?
note: method defined here
    --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/tui-textarea-0.4.0/src/textarea.rs:1770:12
     |
1770 |     pub fn set_cursor_line_style(&mut self, style: Style) {
     |            ^^^^^^^^^^^^^^^^^^^^^

error[E0277]: the trait bound `impl ratatui::widgets::Widget + '_: ratatui::widgets::Widget` is not satisfied
  --> src/inspect/widgets/scan.rs:68:33
   |
68 |                 f.render_widget(self.input.widget(), target);
   |                   ------------- ^^^^^^^^^^^^^^^^^^^ the trait `ratatui::widgets::Widget` is not implemented for `impl ratatui::widgets::Widget + '_`
   |                   |
   |                   required by a bound introduced by this call
   |
   = help: the following other types implement trait `ratatui::widgets::Widget`:
             &W
             &str
             BarChart<'_>
             Canvas<'_, F>
             Chart<'_>
             Gauge<'_>
             LineGauge<'_>
             List<'_>
           and 10 others
note: required by a bound in `ratatui::Frame::<'_>::render_widget`
  --> /Users/olivierbegassat/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/terminal/frame.rs:74:29
   |
74 |     pub fn render_widget<W: Widget>(&mut self, widget: W, area: Rect) {
   |                             ^^^^^^ required by this bound in `Frame::<'_>::render_widget`

Some errors have detailed explanations: E0277, E0308.
For more information about an error, try `rustc --explain E0277`.
error: could not compile `corset` (bin "corset") due to 18 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `corset v9.7.12 (/Users/olivierbegassat/dev/rust/corset)`, intermediate artifacts can be found at `/Users/olivierbegassat/dev/rust/corset/target`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.
@OlivierBBB
Copy link
Collaborator Author

OlivierBBB commented Jun 25, 2024

This is a somewhat pressing issue for us 🙂. @letypequividelespoubelles was able to build corset 5 days ago, I tried this morning and both @lorenzogentile404 and I got the above issue (18 errors etc...).

@lorenzogentile404 and I are on different versions of cargo and rustc and I had this issue on rustc 1.77 (?) and tried upgrading to the latest version (1.79) and it didn't change the issue.

WRT git I pulled the latest main before cargo install --path .'ing it.

@DavePearce
Copy link
Collaborator

Hmmm, ok that is a strange looking error. Its like two versions of ratatui are being defined.

@DavePearce
Copy link
Collaborator

Ok, yes I can recreate the issue on my machine.

@DavePearce
Copy link
Collaborator

We can see that two versions of ratatui are being compiled against:

note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/djp/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.26.3/src/style.rs:227:1
     |
227  | pub struct Style {
     | ^^^^^^^^^^^^^^^^
note: `ratatui::style::Style` is defined in crate `ratatui`
    --> /Users/djp/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ratatui-0.27.0/src/style.rs:228:1

@DavePearce
Copy link
Collaborator

This is some kind of dependency problem. Presumably an upstream dependency has changed the version of ratatui it uses to build, and this has resulted in a clash.

@delehef
Copy link
Contributor

delehef commented Jun 25, 2024

Can you try and adding --locked to the cargo install command?

@OlivierBBB
Copy link
Collaborator Author

I switched back to master and ran cargo install --locked --path . and it also worked.

@DavePearce
Copy link
Collaborator

Can you try and adding --locked to the cargo install command?

That's interesting --- I had assumed that cargo always used the Cargo.lock file when it was available. Good to know.

Still, I will now merge in my simple fix which just updates ratatui to v0.27 to avoid the clash with whatever dependency it is using that version. But I actually don't understand why it is having a problem since Cargo is supposed to manage this.

@DavePearce
Copy link
Collaborator

But I actually don't understand why it is having a problem since Cargo is supposed to manage this.

I guess this is something to do with the ratatui dependency being optional ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants