-
Notifications
You must be signed in to change notification settings - Fork 2
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
👷🐧🍎🏁 Extensive CI testing #60
Conversation
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
@burgholzer I think this can prove a valuable addition to the workflow package. Particularly with respect to our recent discussions on a CI unification across @cda-tum. |
Good point. The build matrix just scales extremely quickly. Given how most of our packages support all currently non-EOL Python versions, the current setup with this PR as it is results in:
on the Python side and
on the C++ side. In total that means at least Each of these runs has to build the C++ part of a project. The Python runs have to additionally install all Python dependencies. Then, all of these runs have to run the respective tests. Setting all the above aside for a moment, we could go one step further in the sense that we could also run on different compilers for each operating system (similar to how fiction handles this). I could imagine it would make sense to test at least
Technically, this applies to both the Python and the C++ builds. So even with the above, it would amount to another factor of 2x in the number of runs. |
I see that this setup quickly grows beyond reason. Naturally, there might not be an immediate end-all-be-all solution to a complex topic like this one. Let me try to list some thoughts on the matter anyway (in no particular order):
I'm always open to discussing this situation further. |
Thanks for your thoughts! 🙏🏼 I'll just add mine in a similar fashion. I agree that one particular compiler version should be sufficient per platform and compiler. I am still a bit on the fence when it comes to caching. First of all, from experience, it is rather opaque and at times hard to judge whether the compiler caches really work the way they are intended to work. Especially on the Python side, it can be quite hard to get that to work properly on all operating systems. Additionally, these caches have to be restored and saved in each run, which also takes quite some time because this has to go through the network. Given how some of the caches are more than a couple of hundred megabytes large, this definitely takes non-zero time. In general, there is a conflict of interest that we will probably never be able to resolve: What could really make a lot of sense is to allow more customization of the individual workflows so that it can be configured on-demand which jobs to run (either automatically based on files that changed, like we already to it at the moment) or via explicit opt-outs (meaning someone would modify the CI.yml in their PR to only enable certain checks they want to run). Self-hosted runners would really go a long way. Especially macOS ones. |
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Added inputs for specifying runner images, compilers, and configurations across Ubuntu, macOS, and Windows workflows. Simplified matrix generation with dynamic configuration, allowing more flexibility in build environments and testing setups. Signed-off-by: burgholzer <burgholzer@me.com>
The workflow is now expected to be called separately like the `reusable-cpp-linter` workflow. Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Totally agreed.
We've had similar experiences in the past. While this is unfortunate, your story validates our findings. At least, we can say now that it wasn't totally on us 😉 That doesn't help with the situation, though obviously.
Also here, I totally agree. In the end, it boils down to a trade-off. Probably, you and I cannot make this decision on a general basis, but only on a repository level. What is good for one repo might be a poor choice for another.
Yes, this goes in the same direction as what I meant to say above: repository-level design decisions should be taken into account when configuring the workflows. It's unfortunate that this then generates code overhead in this repo.
Yessir 🍎 |
Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Alright, I played around a little more with this and correspondingly updated the PR description here. I believe this is a nice start in the right direction. |
Python linting should be called by users. `hynek/build-and-inspect-python-package@v2` is removed as we do test our Python packages extensively anyway. To simplify the configuration, the option to run Python tests individually per Python version is removed as well. Signed-off-by: burgholzer <burgholzer@me.com>
Signed-off-by: burgholzer <burgholzer@me.com>
Great stuff! Looks very promising and not too convoluted even 🙂 |
## Description This PR adopts the latest version of the MQT workflows, which contains the changes from munich-quantum-toolkit/workflows#60. By default, C++ CI is now only run in Release mode for all major platforms. However, when a PR is tagged with `extensive-cpp-ci`, a large set of test runs will be started on various operating system versions using various compilers. Similarly, adding a `extensive-python-ci` label will trigger additional Python test runs on different OS versions. Note that the labels need to be present _before_ CI starts running, or the already started/completed CI may need to be rerun. Most small PRs should be fine to run with the default set of runs. The extensive CI should be enabled for infrastructure-critical PRs or, more generally, at the end of the PR cycle before merging. In addition, this update brings support for natively building `aarch64` wheels using GitHub's new Ubuntu ARM runners, which are now enabled by default. Finally, this PR drops the TestPyPI uploads given their little value over the last couple of months and their substantial runner demand. ## Checklist: <!--- This checklist serves as a reminder of a couple of things that ensure your pull request will be merged swiftly. --> - [x] The pull request only contains commits that are related to it. - [x] I have added appropriate tests and documentation. - [x] I have made sure that all CI jobs on GitHub pass. - [x] The pull request introduces no new warnings and follows the project's style guidelines. --------- Signed-off-by: burgholzer <burgholzer@me.com>
This PR experiments with broadening the type of runners that we run CI on.
In particular, it allows one to dynamically configure the workflow runs that should be enabled.
As a result, projects can decide on their own under which constellations they want to test.
On the C++ side, the currently available workflows are:
with the following combinations being turned on by default:
On the Python side, the available workflows are
with the following runs being turned on by default:
A first prototype how to use this new functionality is being explored in cda-tum/mqt-core#803, where an
extensive-cpp-ci
and anextensive-python-ci
option are added to conditionally run more-than-default testing on demand.Old Description: Due to the amount of runs that this creates, I am rather hesitant to directly merge this. Hence, I will keep this open for now and keep the branch itself. This way, we can test the real-world consequences of this and decide then.