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

fix issues:Image file not deleted when a doc is removed #9541 #10465

Merged
merged 6 commits into from
Nov 11, 2024

Conversation

liuhaoran1212
Copy link
Contributor

Checklist:

Important

Please review the checklist below before submitting your pull request.

  • Please open an issue before creating a PR or link to an existing issue
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I ran dev/reformat(backend) and cd web && npx lint-staged(frontend) to appease the lint gods

Description

Fixed the following issues: When deleting a doc in the web, the doc in "uplaod_files" folder is deleted, but image files extrating from the doc remains in "image_files" folder

Fixes #9541

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update, included: Dify Document
  • Improvement, including but not limited to code refactoring, performance optimization, and UI/UX improvement
  • Dependency upgrade

Testing Instructions

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Test A
  • Test B

Signed-off-by: root <root@localhost.localdomain>
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. 🐞 bug Something isn't working labels Nov 8, 2024
Signed-off-by: root <root@localhost.localdomain>
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. and removed size:S This PR changes 10-29 lines, ignoring generated files. labels Nov 8, 2024
Signed-off-by: root <root@localhost.localdomain>
@crazywoola crazywoola requested a review from laipz8200 November 8, 2024 11:49
laipz8200
laipz8200 previously approved these changes Nov 8, 2024
Copy link
Member

@laipz8200 laipz8200 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

api/core/tools/utils/web_reader_tool.py Outdated Show resolved Hide resolved
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Nov 8, 2024
Signed-off-by: root <root@localhost.localdomain>
root added 2 commits November 11, 2024 10:47
Signed-off-by: root <root@localhost.localdomain>
Signed-off-by: root <root@localhost.localdomain>
Copy link
Member

@laipz8200 laipz8200 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@laipz8200 laipz8200 merged commit 570f10d into langgenius:main Nov 11, 2024
6 checks passed
@liuhaoran1212 liuhaoran1212 deleted the tag_deleteimage branch November 12, 2024 00:40
AlwaysBluer pushed a commit to AlwaysBluer/dify that referenced this pull request Nov 14, 2024
… (langgenius#10465)

Signed-off-by: root <root@localhost.localdomain>
Co-authored-by: root <root@localhost.localdomain>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Image file not deleted when a doc is removed
2 participants