[PR #973] [MERGED] Fix:condition for dataset availability check #22808

Closed
opened 2026-02-21 20:19:48 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/langgenius/dify/pull/973
Author: @yezhwi
Created: 8/23/2023
Status: Merged
Merged: 8/23/2023
Merged by: @JohnJyong

Base: mainHead: develop


📝 Commits (2)

  • 2d57ddd 🐞 fix(his_testing_service):
  • f99747f Merge branch 'langgenius:main' into develop

📊 Changes

2 files changed (+3 additions, -1 deletions)

View changed files

📝 api/services/hit_testing_service.py (+1 -1)
📝 web/.gitignore (+2 -0)

📄 Description

Fix condition for dataset availability check

The condition in the code was checking the same attribute twice, which resulted in incorrect evaluation. This commit updates the condition to check the correct attribute, available_segment_count, instead of available_document_count. Now, the check accurately determines the availability of the dataset based on the correct attribute. This fix ensures the code behaves as intended.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/langgenius/dify/pull/973 **Author:** [@yezhwi](https://github.com/yezhwi) **Created:** 8/23/2023 **Status:** ✅ Merged **Merged:** 8/23/2023 **Merged by:** [@JohnJyong](https://github.com/JohnJyong) **Base:** `main` ← **Head:** `develop` --- ### 📝 Commits (2) - [`2d57ddd`](https://github.com/langgenius/dify/commit/2d57ddd1640828222150d1fd08a2a1fa47e20adf) 🐞 fix(his_testing_service): - [`f99747f`](https://github.com/langgenius/dify/commit/f99747facf62c958e3f61108b2e635f7251a0a14) Merge branch 'langgenius:main' into develop ### 📊 Changes **2 files changed** (+3 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `api/services/hit_testing_service.py` (+1 -1) 📝 `web/.gitignore` (+2 -0) </details> ### 📄 Description Fix condition for dataset availability check The condition in the code was checking the same attribute twice, which resulted in incorrect evaluation. This commit updates the condition to check the correct attribute, `available_segment_count`, instead of `available_document_count`. Now, the check accurately determines the availability of the dataset based on the correct attribute. This fix ensures the code behaves as intended. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-21 20:19:48 -05:00
yindo closed this issue 2026-02-21 20:19:48 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#22808