Upgrade starlark-go (20240311180835-efac67204ba7)#204
Upgrade starlark-go (20240311180835-efac67204ba7)#204romain-h wants to merge 1 commit intocaketop:mainfrom
Conversation
Upgrade the Go starlark package to latest one. This involves a rewrite of the test_configure.py since the starlark resolver configuration is evaluated part of the exec. This is because using global config vars is deprecated now. This is not replacing the usage of it yet as it would involve breaking change of the API.
|
Thanks! I'm trying to understand this; it looks like If so, that seems like kind of a breaking change to this module's API anyway; maybe it would be better to go ahead and change the API to get rid of global config vars altogether (and/or maybe add some sort of Context object to hold defaults as a replacement for them) and bump the major version. What do you think? |
|
Yes indeed, this is already introducing a breaking change. In this case, as you said, we should remove For example, applied to the from starlark_go import Starlark, FileOptions
s = Starlark()
file_options = FileOptions(allow_recursion=True)
x = s.eval("7.7", file_options=file_options) |
Upgrade the Go starlark package to the latest one.
This involves a rewrite of the
test_configure.pysince the starlark resolver configuration is evaluated part of the exec. Using global config vars is deprecated and should be replaced. Not part of this PR as it would involve a breaking change of the API.