build: Bump ruff version to 0.9.7 (#6614)

* Bump ruff version to 0.9.7

* [autofix.ci] apply automated fixes

* refactor: Update Gmail Agent starter project to Langflow 1.2.0

This commit updates the Gmail Agent starter project with new node IDs and configuration reflecting Langflow version 1.2.0. Changes include:
- Updated node identifiers for Agent, ChatInput, ChatOutput, and ComposioAPI
- Refreshed project metadata and version information
- Minor adjustments to node configurations and viewport settings

* [autofix.ci] apply automated fixes

* fix: Revert Gmail Agent name to original

* fix: Remove trailing comma in Gmail Agent JSON

* feat: Add tags to Gmail Agent starter project

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
This commit is contained in:
Christophe Bornet 2025-02-26 21:36:36 +01:00 • committed by GitHub
commit d9b8211a18
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
38 changed files with 214 additions and 207 deletions

View file

@ -57,7 +57,7 @@ async def test_update_component_outputs(client: AsyncClient, logged_in_headers:
async def test_update_component_model_name_options(client: AsyncClient, logged_in_headers: dict):
"""Test that model_name options are updated when selecting a provider."""
component = AgentComponent()
component_node, cc_instance = build_custom_component_template(
component_node, _cc_instance = build_custom_component_template(
component,
)

View file

@ -271,9 +271,9 @@ class TestChromaVectorStoreComponent(ComponentTestBaseWithoutClient):
assert isinstance(data_obj, Data)
assert "id" in data_obj.data
assert "text" in data_obj.data
assert data_obj.data["text"] in ["Document 1", "Document 2"]
assert data_obj.data["text"] in {"Document 1", "Document 2"}
assert "metadata_field" in data_obj.data
assert data_obj.data["metadata_field"] in ["value1", "value2"]
assert data_obj.data["metadata_field"] in {"value1", "value2"}
def test_chroma_collection_to_data_without_metadata(
self, component_class: type[ChromaVectorStoreComponent], default_kwargs: dict[str, Any]
@ -300,7 +300,7 @@ class TestChromaVectorStoreComponent(ComponentTestBaseWithoutClient):
assert isinstance(data_obj, Data)
assert "id" in data_obj.data
assert "text" in data_obj.data
assert data_obj.data["text"] in ["Simple document 1", "Simple document 2"]
assert data_obj.data["text"] in {"Simple document 1", "Simple document 2"}
def test_chroma_collection_to_data_empty_collection(
self, component_class: type[ChromaVectorStoreComponent], default_kwargs: dict[str, Any]

View file

@ -869,7 +869,7 @@ def test_get_sorted_vertices_with_unconnected_graph():
predecessor_map = {vertex: data["predecessors"] for vertex, data in graph_dict.items()}
def is_input_vertex(vertex_id: str) -> bool:
return vertex_id in ["A"]
return vertex_id == "A"
def get_vertex_predecessors(vertex_id: str) -> list[str]:
return predecessor_map[vertex_id]

View file

@ -263,13 +263,13 @@ class TestSerializationHypothesis:
assert isinstance(serialize(np.uint64(42)), int)
# Test floats
assert serialize(np.float64(3.14)) == 3.14
assert isinstance(serialize(np.float64(3.14)), float)
assert serialize(np.float64(math.pi)) == math.pi
assert isinstance(serialize(np.float64(math.pi)), float)
# Test float32 (need to account for precision differences)
float32_val = serialize(np.float32(3.14))
float32_val = serialize(np.float32(math.pi))
assert isinstance(float32_val, float)
assert abs(float32_val - 3.14) < 1e-6 # Check if close enough
assert abs(float32_val - math.pi) < 1e-6 # Check if close enough
# Test bool
assert serialize(np.bool_(True)) is True # noqa: FBT003