Files
crewAI/tests/crew_test.py
Vinicius Brasil 70cd98035f Identify parent_flow of a crew
This commit adds a new crew field called `parent_flow`, evaluated when
the `Crew` instance is instantiated. The stacktrace is traversed to look
up if the caller is an instance of `Flow`, and if so, it fills in the
field.

Other alternatives were considered, such as a global context or even a
new field to be manually filled, however, this is the most **magical**
solution that was thread-safe and did not require public API changes.
2025-05-02 14:00:02 -03:00

158 KiB