graphgate icon indicating copy to clipboard operation
graphgate copied to clipboard

Check strings for matching enum variants which can be passed in from variables

Open dhendrie91 opened this issue 4 years ago • 4 comments
trafficstars

…variables

dhendrie91 avatar Nov 05 '21 12:11 dhendrie91

Ran into this, is there anything holding this back?

jamesbirtles avatar Mar 26 '22 13:03 jamesbirtles

@jamesbirtles so this fix works (we've been running it in production since I submitted this PR) however it means Graphgate isn't fully spec compliant as it will try and process any string to a matching enum variant, not just ones passed as a variable, in practice this isn't really an issue. Been meaning to take a look at it again to get it, but from what I remember it's tricky as we lose the context for values at the point the enum check is carried out, so we don't know if an argument is just a string or a string passed in as a variable, so this would need a bigger fix. Will hopefully get another look at this very soon

dhendrie91 avatar Mar 27 '22 09:03 dhendrie91

@sunli829 do you have any opinions on the above comments ?

dhendrie91 avatar Mar 28 '22 07:03 dhendrie91

@dhendrie91 @jamesbirtles any updates on this

Jonatthu avatar Jan 29 '23 18:01 Jonatthu