TS: Creating default cluster causing unexpected json error
See original GitHub issueWhat happened?
Creating a default cluster throws failed with an unhandled exception: SyntaxError: Unexpected end of JSON input
Steps to reproduce
Run pulumi up
import { Cluster } from '@pulumi/eks';
// Create an EKS cluster.
const cluster = new Cluster('cluster');
Expected Behavior
Creates eks cluster.
Actual Behavior
Fails an throws the following error:
failed with an unhandled exception: SyntaxError: Unexpected end of JSON input
Versions used
Pulumi
CLI
Version 3.35.3
Go Version go1.17.11
Go Compiler gc
Host
OS darwin
Version 11.6.3
Arch x86_64
TS
"@pulumi/eks": "^0.41.0",
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you’ve opened one already).
Issue Analytics
- State:
- Created a year ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Importing json file in typescript causing "Unexpected token ...
My solution to this problem was to just create a class that contained my JSON object and use it in combination with the...
Read more >What Is JSON and How to Handle an “Unexpected Token” Error
The first thing to do in this situation is to confirm where the error is happening exactly. To ensure the error happens on...
Read more >Best Practices for Node.js Error-handling - Toptal
This article will introduce you to error-handling in Node.js and ... causing notorious “callback hell” issues that make it hard to follow the...
Read more >NiFi System Administrator's Guide - Apache NiFi
Within the conf directory, the flow.json.gz file is created ... nifi.cluster.node.protocol.port ... Doing so can cause a surprising bump in throughput.
Read more >Troubleshooting - Amazon ElastiCache for Redis
The default port is 11211 for Memcached and 6379 for Redis. ... Source: 0.0.0.0/0 (or create individial rules for the ElastiCache cluster subnets)....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

I just had the same issue. What solved it for me was to select a context for kubectl (I had no selected context the when the error accoured). Maybe this will help 😃
Yeah this happened to me as well because of a bad
~/.kube/configeven though the associated file was nothing to do with my pulumi stack. Removing that file fixed it.