You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a way to tell which version of the tree-sitter library we're running, at runtime? I didn't find this in api.h.
The goal is to be able to log which version is being used, in particular on systems that use dynamic linking. This would allow all sorts of troubleshooting, such as knowing which bugs we can expect to be fixed, performance enhancements, and all the unexpected.
If I'm correct about the above, then I suggest exposing a ts_library_version variable in api.h. Its value could be the official release ID if there is one, otherwise it would fall back to the git commit ID. For instance, it could be 0.20.6 or a882d0b036b0da23cde5caa1325089b4ca4750ba.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Is there a way to tell which version of the tree-sitter library we're running, at runtime? I didn't find this in
api.h
.The goal is to be able to log which version is being used, in particular on systems that use dynamic linking. This would allow all sorts of troubleshooting, such as knowing which bugs we can expect to be fixed, performance enhancements, and all the unexpected.
For example, homebrew provides a single tree-sitter package which is right now at 0.20.6. Our own semgrep package (formula) depends on this but I don't see a way to specify a version constraint on the tree-sitter library.
If I'm correct about the above, then I suggest exposing a
ts_library_version
variable inapi.h
. Its value could be the official release ID if there is one, otherwise it would fall back to the git commit ID. For instance, it could be0.20.6
ora882d0b036b0da23cde5caa1325089b4ca4750ba
.Beta Was this translation helpful? Give feedback.
All reactions