https://pulumi.com logo
Title
a

alert-salesmen-99166

04/19/2023, 3:30 PM
Greetings, At the moment I am trying to add Import Feature to My Proof-of-concept Provider. I succsefuly implemented create,update,delete,diff,check methods, but I can not implement a Read properly. I am a little bit confused becase nodejs return signature is different from the go signature and I couldn't find an example for nodejs. My signature, but I tried also include inputs here and only inputs. Is it something about my code( if yes, can you please give some advice) or at the moment there is no import feature for nodejs providers?
{
	id:AsIRececivedIt,
	props:{
	allKeysOfTheBackend
}
}
e

echoing-dinner-19531

04/19/2023, 7:19 PM
It looks like read should be working for nodejs. it expects a function
read(id string, urn string, props any)
which should return a struct like you've got above (with id and props)
a

alert-salesmen-99166

04/21/2023, 6:56 AM
Sorry for the late response, but I am still facing the same error "Preview failed: provider does not support importing resources; please try updating the 'ubuntu' plugin". I only found the message is same as in pkg>resource>deploy>step.go line:1040. Is there any example with working nodejs read method that is working or any place in which you think would be better to search for the error?
e

echoing-dinner-19531

04/22/2023, 8:55 AM
Can you raise an issue at https://github.com/pulumi/pulumi/issues, preferably with a snippet showing what your read method currently looks like.