Skip to content

Add check for migrator filename uniqueness#7691

Draft
h-vetinari wants to merge 25 commits into
conda-forge:mainfrom
h-vetinari:check_name
Draft

Add check for migrator filename uniqueness#7691
h-vetinari wants to merge 25 commits into
conda-forge:mainfrom
h-vetinari:check_name

Conversation

@h-vetinari

Copy link
Copy Markdown
Member

@conda-forge-admin

Copy link
Copy Markdown
Contributor

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe/meta.yaml) and found it was in an excellent condition.

@beckermr

Copy link
Copy Markdown
Member

See my comment on the smithy issue. GH search only covers up to 4000 feedstocks. So this approach won't work.

@h-vetinari

Copy link
Copy Markdown
Member Author

See my comment on the smithy issue. GH search only covers up to 4000 feedstocks. So this approach won't work.

what you quoted is that it will find only up to 4000 repos. But we only need the search to return a single hit for things to fail. The limit is not relevant for this detection.

@h-vetinari

Copy link
Copy Markdown
Member Author

Well... In principle it works (even better than I expected, whole check completes in <10sec).

The only big problem I'm running into is that none of Github's APIs actually seems to expose the "new" search that powers the results from the web UI (which returns the correct result). I've tried working around this in a couple of ways, but short of parsing the HTML after querying the web UI, I don't see how to run that search correctly.

On the one hand I'd have been fairly optimistic that github will add this eventually, but OTOH, people have been asking for graphql integration of code search for at least ~8 years with no success, which doesn't exactly inspire confidence 😑

It's surprisingly hard to find out the current status about potential plans for the better search API to be exposed programmatically.

@beckermr

Copy link
Copy Markdown
Member

I am almost 100% sure the text implies github won't search all of our repositories. It says

To keep the REST API fast for everyone, we limit the number of repositories a query will search through.

They are not limiting the results, but instead the number of repos searched.

@beckermr

Copy link
Copy Markdown
Member

repost of my comment on another thread.

@h-vetinari

h-vetinari commented Aug 22, 2025

Copy link
Copy Markdown
Member Author

They are not limiting the results, but instead the number of repos searched.

You left out the following sentence which makes it clear (to me at least) that this is about search results. "The REST API will find up to 4,000 repositories that match your filters and return results from those repositories."

Their API even provides a response whether the search results are complete

Got {
  "total_count": 0,
  "incomplete_results": false,      # <----
  "items": [
  ]
}

I strongly doubt that they can even technically limit the number of repos they search, because it's all based on a giant index, and not individually walking the repos.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants