question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

A basic CI asv check would be useful

See original GitHub issue

Is your feature request related to a problem? Please describe. Currently there’s no automated check to ensure that changes to the benchmarks are valid. For example in #1443 and #1445 I think currently the best way to be sure that the new benchmarks are valid (i.e. they won’t error when being run in the nightly job) is to checkout the PR locally and try it out manually. It would be nice if this was done automatically somehow.

An automated benchmark check would also prevent us from forgetting to update the benchmarks when we make breaking changes to pvlib itself.

Describe the solution you’d like A new github actions workflow that builds the asv environments and executes the benchmarks at least once to ensure validity. Note that I’m not suggesting that we actually use the timing results for anything: the goal is to verify that the benchmarks execute without error, not to detect performance regressions. The latter will still be the nightly VM’s responsibility.

Describe alternatives you’ve considered Running the benchmarks in earnest for PRs would also solve this, but that is still a complicated problem that I don’t want to take on at this point. I think this small step in that direction makes more sense for now.

Additional context asv run --quick seems to do what I want (ref):

Do a “quick” run, where each benchmark function is run only once. This is useful to find basic errors in the benchmark functions faster. The results are unlikely to be useful, and thus are not saved.

--strict is probably also useful here, although see https://github.com/airspeed-velocity/asv/issues/1199

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:3
  • Comments:10 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
roger-lcccommented, Apr 27, 2022

I have added --show-stderr in workflow.yml. But it didn’t show error traceback in summary. I am a little confused with the sed command. And I will learn about it later. image image

  • Would it make sense to use --show-stderr to show information about failed benchmarks? Right now it just prints the name of the failed benchmark, which is fine, but some more information (like an error traceback or something) would be nice.

I have tried to omit --python=same . However, it will shows Unknown branch master in configuration. And I didn’t find something about the branch in asv.conf. image

  • I think it makes sense to omit --python=same so that the environments specified in the configuration file are used. That would make it so that you don’t have to pip install ephem and numba in the workflow file too.
1reaction
kanderso-nrelcommented, Apr 26, 2022

Thanks @roger-lcc, this looks great! A couple comments:

  • Would it make sense to use --show-stderr to show information about failed benchmarks? Right now it just prints the name of the failed benchmark, which is fine, but some more information (like an error traceback or something) would be nice.
  • I think it makes sense to omit --python=same so that the environments specified in the configuration file are used. That would make it so that you don’t have to pip install ephem and numba in the workflow file too.

Is it time to open a PR containing that workflow file? It would be good to get this in place before merging #1443 and #1445.

Read more comments on GitHub >

github_iconTop Results From Across the Web

asv continuous using existing environment (like "--python same")
When developing on a branch, you can use asv continuous branch to check the performance of that branch to master.
Read more >
airspeed velocity Documentation
Instead, airspeed velocity provides a simple static webserver that can be used to preview the website. Just run: asv preview.
Read more >
PCI ASV External FAQ | Tenable®
PCI ASV refers to requirement 11.2.2 of the Payment Card Industry (PCI) Data Security Standard (DSS) Requirements and Security Assessment Procedures that ...
Read more >
Contributing to the code base — pandas 1.4.2 documentation
It is possible to run the checks independently by using the parameters docstring , code , typing , and doctests (e.g. ./ci/code_checks.sh doctests...
Read more >
https://scikit-learn.org/dev/_sources/developers/c...
It's good practice to never work on the ``main`` branch! 9. ... but they will be caught by the CI so you don't...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found