Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues related to the deletion of conversation_id #12488

Closed
5 tasks done
Bkk-shuai opened this issue Jan 8, 2025 · 4 comments · Fixed by #12665
Closed
5 tasks done

Issues related to the deletion of conversation_id #12488

Bkk-shuai opened this issue Jan 8, 2025 · 4 comments · Fixed by #12665
Labels
🐞 bug Something isn't working good first issue Good first issue for newcomers

Comments

@Bkk-shuai
Copy link

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

0.15.0

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

I wrote an Agent using DIY and successfully called its API, but during testing, I found that after deleting conversion_id, I could still call the deleted conversation but could not delete it again
屏幕截图 2025-01-08 164403

✔️ Expected Behavior

image
first I get the new conversation_id called 62b332d8-3a38-43d8-8ac4-8e2c1deee231
then
I used http://xxx/v1/conversations/62b332d8-3a38-43d8-8ac4-8e2c1deee231
get success
image
but When I use the same id with /v1/chat-messages

image
It's still work

❌ Actual Behavior

I think the conversion_id after the DELETE operation should not exist

Copy link

dosubot bot commented Jan 8, 2025

Hey @Bkk-shuai! I'm here to help you with any bugs, questions, or contributions while you wait for a human maintainer. Let's tackle this issue together!

I found a similar unsolved discussion titled Help : Cannot delete conversation, which might be related to your issue [1].

Regarding your issue, the expected behavior of the DELETE operation on a conversation_id in the Dify codebase is to mark the conversation as deleted by setting the is_deleted attribute to True, rather than permanently removing it from the database. This means that while the conversation is marked as deleted, it might still be accessible for certain operations, which seems to be what you're experiencing [2].

If you are able to interact with a conversation after it has been marked as deleted, it might be due to the system's design to allow certain operations on "soft-deleted" conversations. However, if this behavior is not what you expect, it might be worth checking if there are any configuration settings or additional logic in your implementation that could affect this behavior.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@dosubot dosubot bot added the 🐞 bug Something isn't working label Jan 8, 2025
@crazywoola crazywoola added the good first issue Good first issue for newcomers label Jan 8, 2025
@crazywoola crazywoola changed the title Issues related to the deletion of conversion_id Issues related to the deletion of conversaion_id Jan 8, 2025
@crazywoola crazywoola changed the title Issues related to the deletion of conversaion_id Issues related to the deletion of conversation_id Jan 8, 2025
@Bkk-shuai
Copy link
Author

嘿 !在您等待人工维护者时,我在这里帮助您解决任何错误、问题或贡献。让我们一起解决这个问题!

我发现了一个类似的未解决的讨论,标题为 Help : Cannot delete conversation,这可能与您的问题有关[1].

关于您的问题,在 Dify 代码库中对 a 执行 DELETE 操作的预期行为是通过将属性设置为 ,而不是将其从数据库中永久删除,从而将对话标记为已删除。这意味着,虽然对话被标记为已删除,但某些操作可能仍可访问它,这似乎就是您正在经历的情况conversation_id``is_deleted``True[2].

如果会话被标记为已删除后,您能够与会话进行交互,则可能是由于系统的设计允许对 “soft-deleted” 会话执行某些操作。但是,如果此行为不是您所期望的,则可能值得检查您的实施中是否有任何可能影响此行为的配置设置或其他逻辑。

要继续与 Dosu 交谈,请提及 。

帮助 Dosu 学习!给它反馈:伟大的回应 |无关紧要的答案 |不正确的来源 |太冗长 |幻觉 |其他

If I have a large number of new conversation requests or if the same user restarts new conversations, will it cause system congestion

Copy link

dosubot bot commented Jan 8, 2025

I couldn't find specific information on how Dify handles high volumes of conversation requests or if it has built-in mechanisms for throttling to prevent system congestion. However, generally, handling a large number of requests efficiently would involve implementing rate limiting, load balancing, and optimizing database queries. You might want to check if there are any configuration settings or infrastructure setups in your deployment that can help manage high traffic.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@kartik-raj7
Copy link

Hey Could you please assign me this issue

jiandanfeng added a commit to jiandanfeng/dify that referenced this issue Jan 13, 2025
jiandanfeng added a commit to jiandanfeng/dify that referenced this issue Jan 13, 2025
jiandanfeng added a commit to jiandanfeng/dify that referenced this issue Jan 14, 2025
Scorpion1221 added a commit to yybht155/dify that referenced this issue Jan 21, 2025
* commit '6db3ae9b8ec2f8491e2c9355056a8693ecd67f47': (22 commits)
  chore: remove webapp ga (langgenius#12909)
  fix: variable panel scrollable (langgenius#12769)
  fix: OpenAI o1 Bad Request Error (langgenius#12839)
  Update deepseek model configuration (langgenius#12899)
  fix: external dataset hit test display issue(langgenius#12564) (langgenius#12612)
  add deepseek-reasoner (langgenius#12898)
  chore(fix): Invalid quotes for using Array[String] in HTTP request node as JSON body (langgenius#12761)
  fix: Issues related to the deletion of conversation_id (langgenius#12488) (langgenius#12665)
  chore(lint): fix quotes for f-string formatting by bumping ruff to 0.9.x (langgenius#12702)
  feat:Support Minimax-Text-01 (langgenius#12763)
  fix: serply credential check query might return empty records (langgenius#12784)
  feat: allow updating chunk settings for the existing documents (langgenius#12833)
  fix: SparkLite API Auth error (langgenius#12781) (langgenius#12790)
  fix: "parmas" spelling mistake. (langgenius#12875)
  Fix suggested_question_prompt (langgenius#12738)
  fix(i18n): correct typo in zh-Hant translation (langgenius#12852)
  chore: fix chinese translation for 'recall' (langgenius#12772)
  fix: DeepSeek API Error with response format active (text and json_object)  (langgenius#12747)
  feat: enhance credential extraction logic based on configurate method (langgenius#12853)
  fix: Fix rerank model switching issue (langgenius#12721)
  ...

# Conflicts:
#	api/core/tools/utils/message_transformer.py
#	api/poetry.lock
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working good first issue Good first issue for newcomers
Projects
None yet
3 participants