Skip to content

Commit 4106d2f

Browse files
committed
Ignas: Document other cycle break strategies
1 parent f90a87d commit 4106d2f

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

docs/sphinx/pypi-dependencies.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,22 @@ pip_parse(
194194
)
195195
```
196196

197+
Alternatively, one could resolve the cycle by removing one leg of it.
198+
199+
For example while `apache-airflow-providers-sqlite` is "baked into" the Airflow
200+
package, `apache-airflow-providers-postgres` is not and is an optional feature.
201+
Rather than listing `apache-airflow[postgres]` in your `requirements.txt` which
202+
would expose a cycle via the extra, one could either _manually_ depend on
203+
`apache-airflow` and `apache-airflow-providers-postgres` separately as
204+
requirements. Bazel rules which need only `apache-airflow` can take it as a
205+
dependency, and rules which explicitly want to mix in
206+
`apache-airflow-providers-postgres` now can.
207+
208+
Alternatively, one could use `rules_python`'s patching features to remove one
209+
leg of the dependency manually. For instance by making
210+
`apache-airflow-providers-postgres` not explicitly depend on `apache-airflow` or
211+
perhaps `apache-airflow-providers-common-sql`.
212+
197213
## Consuming Wheel Dists Directly
198214

199215
If you need to depend on the wheel dists themselves, for instance, to pass them

0 commit comments

Comments
 (0)