>  Q&A  >  본문

'FieldAttr:ToTokens' 특성 바인딩이 충족되지 않음: 오류

EC2(fargate)에 Dockerfile 버전을 배포하고 싶습니다. Cloudwatch에서 다음 오류가 발생합니다. "풀을 생성하지 못했습니다.: 오류(없음)" 나는 이 문제에 대한 해결책을 알아냈습니다. 연결을 설정할 때 build 更改为 build_unchecked에서 방법을 변경했습니다.

그런데 다음과 같은 오류가 발생하여 컴파일할 수 없습니다.

으아아아 으아아아 으아아아 으아아아

참조 전달을 시도했지만 작동하지 않았습니다.

수정 없이 다른 Dockerfile을 빌드하세요. 문제는 Dockerfile에 있습니다.

dev: 빌드가 완료되었습니다.

으아아아

stg: 빌드할 수 없습니다.

error[E0277]: the trait bound `FieldAttr: ToTokens` is not satisfied
   --> /usr/local/cargo/registry/src/github.com-1ecc6299db9ec823/diesel_derives-2.0.1/src/attrs.rs:143:18
    |
143 | impl Spanned for FieldAttr {
    |                  ^^^^^^^^^ the trait `ToTokens` is not implemented for `FieldAttr`
    |
    = help: the following other types implement trait `ToTokens`:
              &'a T
              &'a mut T
              Abi
              Abstract
              AndAnd
              AndEq
              AngleBracketedGenericArguments
              Arm
            and 312 others
    = note: required for `FieldAttr` to implement `quote::spanned::private::Sealed`
note: required by a bound in `quote::spanned::Spanned`
   --> /usr/local/cargo/registry/src/github.com-1ecc6299db9ec823/quote-1.0.25/src/spanned.rs:6:20
    |
6   | pub trait Spanned: private::Sealed {
    |                    ^^^^^^^^^^^^^^^ required by this bound in `Spanned`

error[E0277]: the trait bound `StructAttr: ToTokens` is not satisfied
   --> /usr/local/cargo/registry/src/github.com-1ecc6299db9ec823/diesel_derives-2.0.1/src/attrs.rs:242:18
    |
242 | impl Spanned for StructAttr {
    |                  ^^^^^^^^^^ the trait `ToTokens` is not implemented for `StructAttr`
    |
    = help: the following other types implement trait `ToTokens`:
              &'a T
              &'a mut T
              Abi
              Abstract
              AndAnd
              AndEq
              AngleBracketedGenericArguments
              Arm
            and 312 others
    = note: required for `StructAttr` to implement `quote::spanned::private::Sealed`
note: required by a bound in `quote::spanned::Spanned`
   --> /usr/local/cargo/registry/src/github.com-1ecc6299db9ec823/quote-1.0.25/src/spanned.rs:6:20
    |
6   | pub trait Spanned: private::Sealed {
    |                    ^^^^^^^^^^^^^^^ required by this bound in `Spanned`

For more information about this error, try `rustc --explain E0277`.
error: could not compile `diesel_derives` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to compile `practice-rust v0.1.0 (/usr/src/practice-rust)`, intermediate artifacts can be found at `/usr/src/practice-rust/target`

P粉696891871P粉696891871206일 전316

모든 응답(2)나는 대답할 것이다

  • P粉545910687

    P粉5459106872024-03-28 08:08:07

    안녕하세요. 다음 종속성을 업데이트하는 중에 동일한 오류가 발생했습니다.

    https://github.com/nxthat/nanocl/commit/6b7b19d7ff50d9392b1e56ec1ad67c34ea63 c632

    일부 종속성을 다운그레이드하면 빠르게 문제를 해결할 수 있을까요?

    나도 문제가 무엇인지 알고 싶다

    회신하다
    0
  • P粉659378577

    P粉6593785772024-03-28 00:20:39

    "참조"의 큰 변화로 인해 이런 일이 발생한 것 같습니다. 질문링크

    회신하다
    0
  • 취소회신하다