mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-01-09 08:08:32 +00:00
fix: TypedDict compatibility for Python 3.11 and remove unused imports
- Use typing_extensions.TypedDict instead of typing.TypedDict for Python < 3.12 compatibility - Remove unused pytest import from test_config.py - Remove unused sys import from test_factory.py - Fixes Pydantic error: 'Please use typing_extensions.TypedDict instead of typing.TypedDict on Python < 3.12' Co-Authored-By: João <joao@crewai.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"""Type definitions for Elasticsearch RAG implementation."""
|
||||
|
||||
from typing import Any, Protocol, TypedDict, Union, TYPE_CHECKING
|
||||
from typing_extensions import NotRequired
|
||||
from typing import Any, Protocol, Union, TYPE_CHECKING
|
||||
from typing_extensions import NotRequired, TypedDict
|
||||
from pydantic import GetCoreSchemaHandler
|
||||
from pydantic_core import CoreSchema, core_schema
|
||||
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
"""Tests for Elasticsearch configuration."""
|
||||
|
||||
import pytest
|
||||
|
||||
from crewai.rag.elasticsearch.config import ElasticsearchConfig
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
"""Tests for Elasticsearch factory."""
|
||||
|
||||
import sys
|
||||
from unittest.mock import Mock, patch
|
||||
|
||||
import pytest
|
||||
|
||||
Reference in New Issue
Block a user