The Wayback Machine - https://web.archive.org/web/20221218082951/https://github.com/python/cpython/pull/100258
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gh-100257: summarize_stats: Link failure kinds to GitHub search #100258

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

lpereira
Copy link
Contributor

@lpereira lpereira commented Dec 14, 2022

By adding links to each row in the failure kind table, we can find where in the code that failure kind has been collected by the specialization code. Search is performed only in specialize.c in the python/cpython repo (the script is unaware of forks at the moment).

By adding links to each row in the failure kind table, we can find
where in the code that failure kind has been collected by the
specialization code.
@netlify
Copy link

netlify bot commented Dec 14, 2022

Deploy Preview for python-cpython-preview canceled.

Name Link
🔨 Latest commit 4fa35fc
🔍 Latest deploy log https://app.netlify.com/sites/python-cpython-preview/deploys/639a53fe49fdf6000894537a

@lpereira
Copy link
Contributor Author

lpereira commented Dec 14, 2022

It looks like this:

Screen Shot 2022-12-14 at 3 01 18 PM

Sample search result: array int.

@markshannon
Copy link
Member

markshannon commented Dec 15, 2022

That link returns a page with "We couldn’t find any code matching 'repo:python/cpython path:Python/specialize.c SPEC_FAIL_SUBSCR_ARRAY_INT' ".

Since this can produce misleading search results for branches other than main, it is likely to be counter productive for experimental stats and changes to the stat names.

@mdboom
Copy link
Contributor

mdboom commented Dec 15, 2022

That link returns a page with "We couldn’t find any code matching 'repo:python/cpython path:Python/specialize.c SPEC_FAIL_SUBSCR_ARRAY_INT' ".

Hmm, it works for me.

Since this can produce misleading search results for branches other than main, it is likely to be counter productive for experimental stats and changes to the stat names.

That could be resolved since we know the hash of the Python that produced it, we could include that in the search URL, if GitHub search supports such a thing. That would make them "permanent" in a sense.

IMHO, this is better than nothing despite that issue -- it is hard to know what these snippets of text refer to. Perhaps better (but obviously more work) would be to document them.

@markshannon
Copy link
Member

markshannon commented Dec 15, 2022

@markshannon
Copy link
Member

markshannon commented Dec 15, 2022

I'm not sure linking to the source for the macro is going to help clarify stuff.
For the failure kinds that aren't clear, improving the text seems the best option to me.

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

Successfully merging this pull request may close these issues.

None yet

5 participants