datafusion icon indicating copy to clipboard operation
datafusion copied to clipboard

Add test to prevent circular dependencies from being added

Open andygrove opened this issue 1 year ago • 2 comments

Which issue does this PR close?

Closes https://github.com/apache/arrow-datafusion/issues/9278

Rationale for this change

Add CI check to prevent circular dependencies from being introduced

What changes are included in this PR?

New test

Are these changes tested?

I tested this manually by adding a circular dependency and running cargo test. It correctly failed with:

circular dependency detected from datafusion-physical-plan to self via one of {"datafusion-common", "datafusion-functions", "datafusion", "datafusion-expr", "datafusion-execution", "datafusion-functions-array", "datafusion-optimizer", "datafusion-sql", "datafusion-physical-expr"}

Are there any user-facing changes?

No

andygrove avatar Feb 20 '24 15:02 andygrove

lgtm thanks @andygrove I think in followup we will put this check separately into its own CI task, what do you think?

Hi @comphead. Are you suggesting that we move the test out of datafusion/core/tests and into a separate project in the repo that has tests that are specific to CI?

andygrove avatar Feb 22 '24 01:02 andygrove

lgtm thanks @andygrove I think in followup we will put this check separately into its own CI task, what do you think?

Hi @comphead. Are you suggesting that we move the test out of datafusion/core/tests and into a separate project in the repo that has tests that are specific to CI?

Tbh I haven't thought about moving it to the separate project. The idea was to have a separate CI check for circular dependency test, like we have RAT check, or security audit check

comphead avatar Feb 22 '24 01:02 comphead

Tbh I haven't thought about moving it to the separate project. The idea was to have a separate CI check for circular dependency test, like we have RAT check, or security audit check

Got it. I filed a follow on issue https://github.com/apache/arrow-datafusion/issues/9338 for discussing this. Thanks for the review!

andygrove avatar Feb 25 '24 16:02 andygrove

Thank you @andygrove and @comphead

alamb avatar Feb 26 '24 10:02 alamb