Unwrap unnecessary dict() from union operands

Proprietary

The | operator already produces a fresh dict, so wrapping an operand in dict() is redundant and can be removed. Only a call to the builtin dict on a single positional argument is unwrapped, and only where that argument and the other operand both resolve to dict.

org.openrewrite.python.cleanup.RemoveRedundantConstructorInDictUnion
mod run . --recipe=org.openrewrite.python.cleanup.RemoveRedundantConstructorInDictUnion

Install it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.