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

com.fasterxml.jackson.module.kotlin.MissingKotlinParameterException when choosing an input template in Lambda Run Configurations #3359

Closed
ghaiszaher opened this issue Oct 27, 2022 · 2 comments
Labels
bug We can reproduce the issue and confirmed it is a bug. ready-to-work Fully defined and ready for work

Comments

@ghaiszaher
Copy link

ghaiszaher commented Oct 27, 2022

Describe the bug
I am unable to choose an input template in AWS Lambda run configurations for most of the templates. Only "S3 Delete" and "Scheduled Event" templates work.

To reproduce

  1. Add a new Lambda run configuration (Local or Remote).
  2. Change the input to Text and choose any existing template (except for S3 Delete and Scheduled Event).
  3. Nothing is shown upon choosing the template.
  4. Close the popup and IntelliJ will report an exception coming from the plugin:
Failed to parse Partitions

com.fasterxml.jackson.module.kotlin.MissingKotlinParameterException: Instantiation of [simple type, class software.aws.toolkits.core.region.Partitions] value failed for JSON property partitions due to missing (therefore NULL) value for creator parameter partitions which is a non-nullable type
 at [Source: (FileInputStream); line: 5, column: 1] (through reference chain: software.aws.toolkits.core.region.Partitions["partitions"])
	at com.fasterxml.jackson.module.kotlin.KotlinValueInstantiator.createFromObjectWith(KotlinValueInstantiator.kt:84)
	at com.fasterxml.jackson.databind.deser.impl.PropertyBasedCreator.build(PropertyBasedCreator.java:202)
	at com.fasterxml.jackson.databind.deser.BeanDeserializer._deserializeUsingPropertyBased(BeanDeserializer.java:518)
	at com.fasterxml.jackson.databind.deser.BeanDeserializerBase.deserializeFromObjectUsingNonDefault(BeanDeserializerBase.java:1405)
	at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserializeFromObject(BeanDeserializer.java:351)
	at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:184)
	at com.fasterxml.jackson.databind.deser.DefaultDeserializationContext.readRootValue(DefaultDeserializationContext.java:323)
	at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:4674)
	at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3666)
	at software.aws.toolkits.core.region.PartitionParser$parse$1.invoke(Partitions.kt:48)
	at software.aws.toolkits.core.region.PartitionParser$parse$1.invoke(Partitions.kt:47)
	at software.aws.toolkits.core.utils.LogUtilsKt.tryOrNull(LogUtils.kt:21)
	at software.aws.toolkits.core.utils.LogUtilsKt.tryOrNull$default(LogUtils.kt:20)
	at software.aws.toolkits.core.region.PartitionParser.parse(Partitions.kt:47)
	at software.aws.toolkits.core.region.EndpointsJsonValidator.canBeParsed(Partitions.kt:53)
	at software.aws.toolkits.core.utils.DefaultRemoteResourceResolver.internalResolve(RemoteResourceResolver.kt:69)
	at software.aws.toolkits.core.utils.DefaultRemoteResourceResolver.resolve$lambda$0(RemoteResourceResolver.kt:30)
	at software.aws.toolkits.jetbrains.core.DefaultRemoteResourceResolverProvider$Companion$RESOLVER_INSTANCE$2$1.invoke$lambda$0(RemoteResourceResolverProvider.kt:36)
	at com.intellij.openapi.application.impl.ApplicationImpl$1.run(ApplicationImpl.java:297)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:702)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:699)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:699)
	at java.base/java.lang.Thread.run(Thread.java:833)

Expected behavior
The chosen template should show.

Screenshots

Example of an event that doesn't show:
image

Example of an event that shows (only S3 Delete and Scheduled Event):
image

Exception:
image

Your Environment

  • OS: macOS 13.0 (22A380)
  • JetBrains product: IntelliJ IDEA Ultimate
  • JetBrains product version: 2022.2.3 (Build #IU-222.4345.14, built on October 5, 2022)
  • AWS Toolkit version: 1.52-222
@ghaiszaher ghaiszaher added the bug We can reproduce the issue and confirmed it is a bug. label Oct 27, 2022
@rli rli added the ready-to-work Fully defined and ready for work label Nov 11, 2022
@crashev
Copy link

crashev commented Jan 10, 2023

When will this fix be released?

@vchikoti1998
Copy link
Contributor

Released on Jan 13th.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug We can reproduce the issue and confirmed it is a bug. ready-to-work Fully defined and ready for work
Projects
None yet
Development

No branches or pull requests

4 participants