Search for code options does not include fork:true


I am searching for files including forks, but it seems that the clause fork:true does not work for code options. For example, I am trying this search: universalmutator filename:setup extension:py fork:true, but this query returns the same that universalmutator filename:setup extension:py. Could anyone help me to include forks in the search by code? Is it this a bug?

Thanks in advance,

Hi @belene :wave:

Thanks for making your first post in the community forum!

I am testing the search terms you listed here. However, I do not believe I am getting the same results.

Your first search yields 17 results. All of which are forked repositories.
universalmutator filename:setup extension:py

The second search yields 1 repository.
universalmutator filename:setup extension:py

Hi @ernest-phillips,

Thanks for your response. You are right regarding the repositories returned by the searches. However, I refer to the selection of code related. I mean, if you add the search string and then click Code (on the left panel) always shows the same results for both searches (2 results). I hope I have explained it better.

1 Like

Hi ! My bad, I totally glossed over you explicitly stating for code results.

It looks like you are getting this because the forks of those repositories do not meet the requirement for being indexed in the search results.

Code in forks is only searchable if the fork has more stars than the parent repository. Forks with fewer stars than the parent repository are not indexed for code search. To include forks with more stars than their parent in the search results, you will need to add fork:true or fork:only to your query. For more information, see “Searching in forks.”

You can read more about that here:

If you know of a specific repository that has a fork meeting the search criteria, please let us know.