crossplane / crossplane-tools

Experimental code generators for Crossplane controllers.
https://crossplane.io
Apache License 2.0
34 stars 26 forks source link

add support for float pointer values for references #49

Closed eljohnson92 closed 1 year ago

eljohnson92 commented 1 year ago

Description of your changes

This change allows for types of references that are not strings. some terraform providers use "number" types for resource IDs which seem to get translated to float64 as part of upjet. when trying to use them as references previously only strings were supported, this PR along with a PR #367 in crossplane-runtime allows for "number" IDs to also be supported as references Fixes #

I have:

How has this code been tested

This has been tested by the linode-provider, which is using my forked version of this repo and the crossplane-runtime repo

turkenh commented 1 year ago

@eljohnson92 linter is failing, could you check and fix it?

eljohnson92 commented 1 year ago

@turkenh I did a small refactor to fix the cyclomatic complexity in that function and bring it back below 10. should be good for another review