Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
f49e442
feat: update OpenAI model parameters handling for reasoning models
ogabrielluiz Jun 9, 2025
914fc91
feat: extend input_value type in LCModelComponent to support AsyncIte…
ogabrielluiz Jun 9, 2025
3d7e76c
refactor: remove assert_streaming_sequence method and related checks …
ogabrielluiz Jun 9, 2025
9dd9205
feat: add consume_iterator method to Message class for handling itera…
ogabrielluiz Jun 9, 2025
0623d6b
test: add unit tests for OpenAIModelComponent functionality and integ…
ogabrielluiz Jun 9, 2025
996a3bf
feat: update OpenAIModelComponent to include temperature and seed par…
ogabrielluiz Jun 9, 2025
600ece6
feat: rename consume_iterator method to consume_iterator_in_text and …
ogabrielluiz Jun 9, 2025
b029115
feat: add is_connected_to_chat_output method to Component class for i…
ogabrielluiz Jun 11, 2025
d576d96
feat: refactor LCModelComponent methods to support asynchronous messa…
ogabrielluiz Jun 11, 2025
abc3891
refactor: remove consume_iterator_in_text method from Message class a…
ogabrielluiz Jun 11, 2025
aa24bee
fix: update import paths for input components in multiple starter pro…
ogabrielluiz Jun 11, 2025
452dcb2
fix: enhance error message formatting in ErrorMessage class to handle…
ogabrielluiz Jun 11, 2025
1398034
refactor: remove validate_stream calls from generate_flow_events and …
ogabrielluiz Jun 11, 2025
987f912
fix: handle asyncio.CancelledError in aadd_messagetables to ensure pr…
ogabrielluiz Jun 11, 2025
929fbc2
refactor: streamline message handling in LCModelComponent by replacin…
ogabrielluiz Jun 11, 2025
3714612
refactor: enhance message handling in LCModelComponent by introducing…
ogabrielluiz Jun 12, 2025
cb9ba56
feat: add _build_source method to Component class for enhanced source…
ogabrielluiz Jun 12, 2025
037e553
feat: enhance LCModelComponent by adding _handle_stream method for im…
ogabrielluiz Jun 12, 2025
614fac4
feat: update MemoryComponent to enhance message retrieval and storage…
ogabrielluiz Jun 12, 2025
a1d8421
Merge branch 'main' into improve-streaming
ogabrielluiz Jun 12, 2025
d031c91
test: refactor LanguageModelComponent tests to use ComponentTestBaseW…
ogabrielluiz Jun 12, 2025
1547e9f
test: add fixtures for API keys and implement live API tests for Open…
ogabrielluiz Jun 12, 2025
fdb1ad5
Merge branch 'main' into improve-streaming
ogabrielluiz Jun 23, 2025
0aa9519
fix: reorder JSON properties for consistency in starter projects
ogabrielluiz Jun 23, 2025
663e47e
refactor: simplify input_value type in LCModelComponent
ogabrielluiz Jun 25, 2025
1fd3656
fix: clarify comment for handling source in Component class
ogabrielluiz Jun 25, 2025
2755422
Merge branch 'main' into improve-streaming
ogabrielluiz Jun 25, 2025
c1b8d5f
refactor: remove unnecessary mocking in OpenAI model integration tests
ogabrielluiz Jun 25, 2025
dafb3c0
Merge branch 'main' into improve-streaming
ogabrielluiz Jun 25, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: handle asyncio.CancelledError in aadd_messagetables to ensure pr…
…oper session rollback and retry logic
  • Loading branch information
ogabrielluiz committed Jun 12, 2025
commit 987f91230653235a63bff8b5a96e61131f3b30c3
7 changes: 4 additions & 3 deletions src/backend/base/langflow/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,15 +153,16 @@ async def aupdate_messages(messages: Message | list[Message]) -> list[Message]:

async def aadd_messagetables(messages: list[MessageTable], session: AsyncSession):
try:
for message in messages:
session.add(message)
try:
for message in messages:
session.add(message)
await session.commit()
# This is a hack.
# We are doing this because build_public_tmp causes the CancelledError to be raised
# while build_flow does not.
except asyncio.CancelledError:
await session.commit()
await session.rollback()
return await aadd_messagetables(messages, session)
for message in messages:
await session.refresh(message)
except asyncio.CancelledError as e:
Expand Down