Open anthony-santana opened 1 year ago
Hi @anthony-santana, I believe the style should be enforced, but certain folders, like the tests, are currently excluded for the style check. You can see which files are excluded here. I don't remember why I excluded them; it might be that they can be properly formatted, or it might be that some tests make that difficult.
Required prerequisites
Describe the bug
We run a python formatting check in the CI with yapf, but it appears that it's not actually being enforced. This can be confirmed by
pip install yapf
, then pulling down CUDA Quantum main and runningyapf cuda-quantum/python/tests/unittests -r -i
. For main to be passing the CI, yapf should produce no changes to the code. Instead, it has to reformat multiple files -- indicating the python formatting step isn't throwing an error when it should be.Steps to reproduce the bug
Expected behavior
An error should be thrown in the CI if the python files have not been formatted through yapf.
Is this a regression? If it is, put the last known working version (or commit) here.
Not a regression
Environment
Suggestions
No response