Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dify
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ai-tech
dify
Commits
780f4c72
Commit
780f4c72
authored
Jun 14, 2023
by
jyong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add notion page icon to document
parent
80a3d577
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
document_indexing_sync_task.py
api/tasks/document_indexing_sync_task.py
+1
-1
document_indexing_update_task.py
api/tasks/document_indexing_update_task.py
+1
-1
recover_document_indexing_task.py
api/tasks/recover_document_indexing_task.py
+1
-1
No files found.
api/tasks/document_indexing_sync_task.py
View file @
780f4c72
...
@@ -91,7 +91,7 @@ def document_indexing_sync_task(dataset_id: str, document_id: str):
...
@@ -91,7 +91,7 @@ def document_indexing_sync_task(dataset_id: str, document_id: str):
logging
.
exception
(
"Cleaned document when document update data source or process rule failed"
)
logging
.
exception
(
"Cleaned document when document update data source or process rule failed"
)
try
:
try
:
indexing_runner
=
IndexingRunner
()
indexing_runner
=
IndexingRunner
()
indexing_runner
.
run
(
list
(
document
)
)
indexing_runner
.
run
(
[
document
]
)
end_at
=
time
.
perf_counter
()
end_at
=
time
.
perf_counter
()
logging
.
info
(
click
.
style
(
'update document: {} latency: {}'
.
format
(
document
.
id
,
end_at
-
start_at
),
fg
=
'green'
))
logging
.
info
(
click
.
style
(
'update document: {} latency: {}'
.
format
(
document
.
id
,
end_at
-
start_at
),
fg
=
'green'
))
except
DocumentIsPausedException
:
except
DocumentIsPausedException
:
...
...
api/tasks/document_indexing_update_task.py
View file @
780f4c72
...
@@ -67,7 +67,7 @@ def document_indexing_update_task(dataset_id: str, document_id: str):
...
@@ -67,7 +67,7 @@ def document_indexing_update_task(dataset_id: str, document_id: str):
logging
.
exception
(
"Cleaned document when document update data source or process rule failed"
)
logging
.
exception
(
"Cleaned document when document update data source or process rule failed"
)
try
:
try
:
indexing_runner
=
IndexingRunner
()
indexing_runner
=
IndexingRunner
()
indexing_runner
.
run
(
list
(
document
)
)
indexing_runner
.
run
(
[
document
]
)
end_at
=
time
.
perf_counter
()
end_at
=
time
.
perf_counter
()
logging
.
info
(
click
.
style
(
'update document: {} latency: {}'
.
format
(
document
.
id
,
end_at
-
start_at
),
fg
=
'green'
))
logging
.
info
(
click
.
style
(
'update document: {} latency: {}'
.
format
(
document
.
id
,
end_at
-
start_at
),
fg
=
'green'
))
except
DocumentIsPausedException
:
except
DocumentIsPausedException
:
...
...
api/tasks/recover_document_indexing_task.py
View file @
780f4c72
...
@@ -34,7 +34,7 @@ def recover_document_indexing_task(dataset_id: str, document_id: str):
...
@@ -34,7 +34,7 @@ def recover_document_indexing_task(dataset_id: str, document_id: str):
try
:
try
:
indexing_runner
=
IndexingRunner
()
indexing_runner
=
IndexingRunner
()
if
document
.
indexing_status
in
[
"waiting"
,
"parsing"
,
"cleaning"
]:
if
document
.
indexing_status
in
[
"waiting"
,
"parsing"
,
"cleaning"
]:
indexing_runner
.
run
(
list
(
document
)
)
indexing_runner
.
run
(
[
document
]
)
elif
document
.
indexing_status
==
"splitting"
:
elif
document
.
indexing_status
==
"splitting"
:
indexing_runner
.
run_in_splitting_status
(
document
)
indexing_runner
.
run_in_splitting_status
(
document
)
elif
document
.
indexing_status
==
"indexing"
:
elif
document
.
indexing_status
==
"indexing"
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment