Fix type-checker errors in utils.py

Co-Authored-By: Joe Moura <joao@crewai.com>
This commit is contained in:
Devin AI
2025-04-23 22:00:44 +00:00
parent 7a7736cfc6
commit 4cf90dbcb7

View File

@@ -83,8 +83,9 @@ def _get_project_attribute(
pyproject_content = parse_toml(f.read()) pyproject_content = parse_toml(f.read())
import inspect import inspect
calling_frame = inspect.currentframe().f_back calling_frame = inspect.currentframe()
calling_function = calling_frame.f_code.co_name if calling_frame and calling_frame.f_back and calling_frame.f_back.f_code:
calling_function = calling_frame.f_back.f_code.co_name
if calling_function != "reset_memories": if calling_function != "reset_memories":
dependencies = ( dependencies = (
_get_nested_value(pyproject_content, ["project", "dependencies"]) or [] _get_nested_value(pyproject_content, ["project", "dependencies"]) or []