mozilla / addons

☂ Umbrella repository for Mozilla Addons ✨
Other
128 stars 41 forks source link

[Bug]: build fail in CI if `site-static/` contains python files not passing `ruff` checks #15071

Closed diox closed 1 month ago

diox commented 1 month ago

What happened?

We have ruff running in CI doing a ruff check to make sure our python code is formatted correctly.

ruff ignores files in .gitignore by default... but since https://github.com/mozilla/addons-server/commit/90f997a2d2e our .dockerignore has started ignoring .gitignore itself. In CI, where we do not mount the repos from the host, this is causing ruff to run without that .gitignore, and therefore trying to check formatting of files in site-static/.

That causes https://github.com/mozilla/addons-server/pull/22744 to fail CI because it brings an update of flatten, which contains python code not formatted to our standards.

What did you expect to happen?

CI builds shouldn't fail for unformatted python files in site-static/.

We should either:

Is there an existing issue for this?

┆Issue is synchronized with this Jira Task

ioanarusiczki commented 1 month ago

I'll add a qa not needed.