Description
Just started using the new Next.js app directory in our Rush repo. The feature is listed as "experimental" in Next.js, and they emit this warning during builds:
Because of the warning, our Rush CI build now starts to fail. There's an upstream issue tracking this, but obviously not predictable when it'll be addressed. We obviously could use Rush's allowWarningsInSuccessfulBuild
as an escape hatch here, but I'd rather not sacrifice the integrity of our entire job based on one warning in one dependency.
It would be cool if there was a way to filter out / allow specific warnings during the job. There's obviously a balance here because the reason the setting exists in the first place is to prevent developers from ignoring warnings, but there is a difference between warnings you're fine with / have accepted risks for (i.e. this one in our case) and warnings you're seeing for the first time which should actually fail your job. The practical alternative of turning off warnings for the entire repo seems worse here, and assuming there were some configuration file for allowed warnings, a team could use CODEOWNERS to add technical controls against accepting every warning, and could leave comments that explain the reason for filtering the warning and tracking upstream issues.
Intuitively seems like something that could/should be delivered as a Rush plugin (related in spirit to this open Heft plugin PR). This won't actually work (couldn't find a real way to plug into the Terminal
for a Rush session on first glance) but would imagine code looking something like this:
Metadata
Assignees
Labels
Type
Projects
Status
General Discussions