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

Could not find AccountCapabilities in this scope. #462

Closed
justanotherbyte opened this issue Dec 22, 2023 · 2 comments · Fixed by #452
Closed

Could not find AccountCapabilities in this scope. #462

justanotherbyte opened this issue Dec 22, 2023 · 2 comments · Fixed by #452
Labels
bug Something isn't working

Comments

@justanotherbyte
Copy link

Describe the bug

With the following Cargo.toml:

[dependencies]
async-stripe = { version = "0.26.0", features = ["runtime-tokio-hyper", "checkout", "webhook-events"], default-features = false}

I receive this error when compiling:

cargo run

    Blocking waiting for file lock on build directory
   Compiling async-stripe v0.26.0
error[E0412]: cannot find type `AccountCapabilities` in this scope
   --> /Users/Viswa/.cargo/registry/src/index.crates.io-6f17d22bba15001f/async-stripe-0.26.0/src/resources/webhook_events.rs:428:25
    |
428 |     AccountCapabilities(AccountCapabilities),
    |                         ^^^^^^^^^^^^^^^^^^^ not found in this scope
    |
help: there is an enum variant `crate::EventObject::AccountCapabilities`; try using the variant's enum
    |
428 |     AccountCapabilities(crate::EventObject),
    |                         ~~~~~~~~~~~~~~~~~~

For more information about this error, try `rustc --explain E0412`.
error: could not compile `async-stripe` (lib) due to previous error

I am attempting to use the Webhook::construct_event API, through rocket.rs

To Reproduce

See above's Cargo.toml.

Expected behavior

Compilation to succeed.

Code snippets

No response

OS

macOS

Rust version

1.75.0-nightly

Library version

async-stripe v0.26.0

API version

2023-10-16

Additional context

No response

@justanotherbyte justanotherbyte added the bug Something isn't working label Dec 22, 2023
@mzeitlin11
Copy link
Collaborator

I think this is the same root issue as #137. You might need to add the additional connect feature as a workaround for now

@justanotherbyte
Copy link
Author

I see, this managed to fix my issue, thanks for the help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants