https://pulumi.com logo
#general
Title
# general
w

wide-holiday-59376

08/29/2019, 7:33 PM
https://www.pulumi.com/docs/intro/concepts/programming-model/#diff-id-olds-news states that "olds" is the old output values and "news" is the new input values. Is this a typo? Shouldn't they both be inputs or outputs?
w

white-balloon-205

08/29/2019, 7:56 PM
I believe all of the references to this are correct, and there are indeed a couple of the resource provider APIs that do intentionally mix these. Are you seeing behavior different from this in any case?
w

wide-holiday-59376

08/29/2019, 8:00 PM
I'm having a hard time debugging what is actually going on. I created an implementation that logs what old/new parameters I get and I'm seeing an unexpected value.
Specifically, check() gets an object containing functions for
newInputs
instead of simple key-value pairs like I was expecting.
So it's hard to read the output.
Do you have a simple implementation floating around that implements all methods, even the optional ones?
For oldInputs, I see an object containing
__provider
containing source-code as a value (large string).
w

white-balloon-205

08/29/2019, 8:07 PM
Are you working in JavaScript or Python?
w

wide-holiday-59376

08/29/2019, 8:07 PM
Typescript
I think I'm getting the hang of this... slowly 🙂
But some sample code would help.
f

future-barista-68134

08/29/2019, 8:37 PM
w

wide-holiday-59376

08/29/2019, 8:48 PM
Thanks Dan
Is there a way to instruct
aws.ec2.Instance
to restart some Javascript variable changes value since the last run? I see the
depends
option but it only lets you depend on full-fledged Resources.