question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

‼️ NOTICE: aws-cdk CLI - "Cloud assembly schema version mismatch: Maximum schema version supported is 10.0.0, but found 11.0.0"

See original GitHub issue

Please add your +1 👍 to let us know you have encountered this


Status: IN-PROGRESS

This is a bug in npm version 7 only (npm versions 6 and below work fine). See here for details: https://github.com/npm/cli/issues/3196

Overview:

After upgrading the CDK CLI package (aws-cdk) with npm version 7, running any CDK command in your CDK application fails with the error Cloud assembly schema version mismatch: Maximum schema version supported is 10.0.0, but found 11.0.0.

Complete Error Message

$ npx cdk ls
This CDK CLI is not compatible with the CDK library used by your application. Please upgrade the CLI to the latest version.
(Cloud assembly schema version mismatch: Maximum schema version supported is 10.0.0, but found 11.0.0)

Workaround:

Please remove the installed aws-cdk package, and then install it again:

$ npm uninstall -g aws-cdk
$ npm install -g aws-cdk

Original opening post

This CDK CLI is not compatible with the CDK library used by your application. Please upgrade the CLI to the latest version. (Cloud assembly schema version mismatch: Maximum schema version supported is 10.0.0, but found 11.0.0)

aws-cdk version 1.103.0 and 1.104.0 do not work. aws-cdk version 1.102.0 works fine

Reproduction Steps

Install aws-cdk 1.103.0 (or 1.104.0) pip install -r requirements.txt

cdk ls

What did you expect to happen?

List of stacks displayed

What actually happened?

"This CDK CLI is not compatible with the CDK library used by your application. Please upgrade the CLI to the latest version. (Cloud assembly schema version mismatch: Maximum schema version supported is 10.0.0, but found 11.0.0) "

Environment

  • CDK CLI Version : 1.104.0
  • Framework Version: 1.103.0 & 1.104.0
  • Node.js Version: v16.1.0
  • **OS : Mac Big Sur
  • Language (Version): Python 3.8.7

Other


This is 🐛 Bug Report

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:84
  • Comments:49 (27 by maintainers)

github_iconTop GitHub Comments

13reactions
gshpychkacommented, Jan 12, 2022

This is because schema version 16.0.0 was introduced in CDK 1.139. CDKv2 does not support it yet as of 2.5.0.

Solutions:

  1. Use the 1.139 version of the CDK CLI instead of the latest v2.
  2. Downgrade your construct modules to 1.138
  3. Switch your construct modules to CDKv2.
8reactions
rix0rrrcommented, May 19, 2021

Best I can recommend at this moment is trying:

$ npm uninstall -g aws-cdk
$ npm install -g aws-cdk

And seeing if that fixes it.

NPM left your install in an inconsistent state, and without being able to reproduce it it’s hard to say why.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to solve CDK CLI version mismatch - Stack Overflow
I am installing the cdk cli with npm, and an uninstall followed by an install fixed the issue. npm -g uninstall aws-cdk npm...
Read more >
API reference - AWS Cloud Development Kit (AWS CDK) v2
Cloud assembly schema version mismatch : Maximum schema version supported is 3.0.0, but found 4.0.0. Please upgrade your CLI in order to interact...
Read more >
@aws-cdk/cloud-assembly-schema - npm
It defines the set of instructions that are needed in order to deploy the assembly directory. For example, when cdk deploy is executed,...
Read more >
@aws-cdk/cloud-assembly-schema | Yarn - Package Manager
The AWS Cloud Development Kit (AWS CDK) is an open-source software development framework to define cloud infrastructure in code and provision it through...
Read more >
Hi, I'm working on the AWS CLI and I keep getting | Chegg.com
Please upgrade the CLI to the latest version. (cloud assembly schema version mismatch: Maximum schema version supported is 21.0.0, but found 22.0.0) ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found