Scalable approach to a code search? #178920
Replies: 3 comments 2 replies
-
|
Beta Was this translation helpful? Give feedback.
This comment was marked as off-topic.
This comment was marked as off-topic.
-
|
Is there any word on when Code Search v2 is going to be available in API form? As far as I can tell, there's basically no way to accomplish today what Big Time T-Strings accomplished without trouble just a month ago. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Select Topic Area
Question
Body
About a month ago I built a tiny website called "Big Time T-Strings".
The website shows a list of public repositories on GitHub that use Python 3.14's new t-strings feature, which just shipped.
To do this, an action is run daily that uses
gh search codeto identify repositories with apyproject.tomlthat declares a minimum dependency on Python 3.14. We then shallow clone each such repository and parse the python files, looking for uses of t-strings (containsast.TemplateStror imports fromstring.templatelib).This has been working without problem until a few days ago. The
gh search codeinvocation that has been used since I first built the project is no longer returning consistent results, and is most definitely not returning a full result set anymore. (3.14 is new enough that there are roughly 500 such repositories at the moment; something changed behind the scenes and I often get far fewer than 100 returned today)I know from the documentation that
gh search codeuses the "legacy search API". But I don't really see another better API available to perform a search that looks like this one:So, two questions:
Does anyone know if something material changed with the "legacy code search" endpoint in the past week or so?
Can anyone suggest a scalable approach that meets GitHub's terms of service and that would allow me to identify all such repositories? Is there one?
Thanks! This is just a fun side project, but I'd love to figure out how to do this in a way that doesn't tax GitHub and scales nicely.
Cheers,
Dave
Beta Was this translation helpful? Give feedback.
All reactions