linklayer / cantact

Drivers and Command Line Interface for CANtact tools
http://cantact.io
MIT License
46 stars 11 forks source link

cantact 0.0.6 Fails to Compile #6

Closed caleb-cotter closed 3 years ago

caleb-cotter commented 3 years ago

Trying to install the CLI

cargo install cantact

yields

error[E0308]: mismatched types
  --> /Users/Caleb/.cargo/registry/src/github.com-1ecc6299db9ec823/cantact-0.0.6/src/main.rs:37:9
   |
36 |     let result = match matches.subcommand() {
   |                        -------------------- this expression has type `std::option::Option<(&str, &ArgMatches)>`
37 |         ("dump", Some(m)) => dump::cmd(m),
   |         ^^^^^^^^^^^^^^^^^ expected enum `std::option::Option`, found tuple
   |
   = note: expected enum `std::option::Option<(&str, &ArgMatches)>`
             found tuple `(_, _)`

error[E0308]: mismatched types
  --> /Users/Caleb/.cargo/registry/src/github.com-1ecc6299db9ec823/cantact-0.0.6/src/main.rs:38:9
   |
36 |     let result = match matches.subcommand() {
   |                        -------------------- this expression has type `std::option::Option<(&str, &ArgMatches)>`
37 |         ("dump", Some(m)) => dump::cmd(m),
38 |         ("send", Some(m)) => send::cmd(m),
   |         ^^^^^^^^^^^^^^^^^ expected enum `std::option::Option`, found tuple
   |
   = note: expected enum `std::option::Option<(&str, &ArgMatches)>`
             found tuple `(_, _)`

error[E0308]: mismatched types
  --> /Users/Caleb/.cargo/registry/src/github.com-1ecc6299db9ec823/cantact-0.0.6/src/main.rs:39:9
   |
36 |     let result = match matches.subcommand() {
   |                        -------------------- this expression has type `std::option::Option<(&str, &ArgMatches)>`
...
39 |         ("cfg", Some(m)) => cfg::cmd(m),
   |         ^^^^^^^^^^^^^^^^ expected enum `std::option::Option`, found tuple
   |
   = note: expected enum `std::option::Option<(&str, &ArgMatches)>`
             found tuple `(_, _)`

error: aborting due to 3 previous errors

For more information about this error, try `rustc --explain E0308`.
error: failed to compile `cantact v0.0.6`, intermediate artifacts can be found at `/var/folders/q8/htqqyj350d930yhcyk8d64t00000gn/T/cargo-installOcoO31`

Caused by:
  could not compile `cantact`
brainstorm commented 3 years ago

Same here. Compile from master seems fine, this version (0.0.6) on crates.io is broken.

brainstorm commented 3 years ago

@ericevenchick Could you just push the release on master (0.0.7)?

brainstorm commented 3 years ago

Release 0.1.0 is out... @ericevenchick, would you mind closing this issue and paying some attention to the other issues and PRs?

ericevenchick commented 3 years ago

Sorry, missed this issue. It's fixed with the 0.1.0 release. I'll take a look at your PR too 😃

...tbh CANtact dev has been a bit slow due to work stuff over the past few months but I'm trying to carve out more time for it.