Fix linting
This commit is contained in:
@@ -423,7 +423,7 @@ def create_app(args):
|
||||
"""Get current system status"""
|
||||
try:
|
||||
pipeline_status = await get_namespace_data("pipeline_status")
|
||||
|
||||
|
||||
username = os.getenv("AUTH_USERNAME")
|
||||
password = os.getenv("AUTH_PASSWORD")
|
||||
if not (username and password):
|
||||
@@ -454,7 +454,7 @@ def create_app(args):
|
||||
"core_version": core_version,
|
||||
"api_version": __api_version__,
|
||||
"auth_mode": auth_mode,
|
||||
"pipeline_busy": pipeline_status.get("busy", False)
|
||||
"pipeline_busy": pipeline_status.get("busy", False),
|
||||
}
|
||||
except Exception as e:
|
||||
logger.error(f"Error getting health status: {str(e)}")
|
||||
|
@@ -892,7 +892,9 @@ class LightRAG:
|
||||
# Get first document's file path and total count for job name
|
||||
first_doc_id, first_doc = next(iter(to_process_docs.items()))
|
||||
first_doc_path = first_doc.file_path
|
||||
path_prefix = first_doc_path[:20] + ("..." if len(first_doc_path) > 20 else "")
|
||||
path_prefix = first_doc_path[:20] + (
|
||||
"..." if len(first_doc_path) > 20 else ""
|
||||
)
|
||||
total_files = len(to_process_docs)
|
||||
job_name = f"{path_prefix}[{total_files} files]"
|
||||
pipeline_status["job_name"] = job_name
|
||||
|
@@ -55,7 +55,7 @@ export default function PipelineStatusDialog({
|
||||
const isAtBottom = Math.abs(
|
||||
(container.scrollHeight - container.scrollTop) - container.clientHeight
|
||||
) < 1
|
||||
|
||||
|
||||
if (isAtBottom) {
|
||||
setIsUserScrolled(false)
|
||||
} else {
|
||||
@@ -92,7 +92,7 @@ export default function PipelineStatusDialog({
|
||||
)}
|
||||
>
|
||||
<DialogDescription className="sr-only">
|
||||
{status?.job_name
|
||||
{status?.job_name
|
||||
? `${t('documentPanel.pipelineStatus.jobName')}: ${status.job_name}, ${t('documentPanel.pipelineStatus.progress')}: ${status.cur_batch}/${status.batchs}`
|
||||
: t('documentPanel.pipelineStatus.noActiveJob')
|
||||
}
|
||||
@@ -101,7 +101,7 @@ export default function PipelineStatusDialog({
|
||||
<DialogTitle className="flex-1">
|
||||
{t('documentPanel.pipelineStatus.title')}
|
||||
</DialogTitle>
|
||||
|
||||
|
||||
{/* Position control buttons */}
|
||||
<div className="flex items-center gap-2 mr-8">
|
||||
<Button
|
||||
@@ -174,7 +174,7 @@ export default function PipelineStatusDialog({
|
||||
{/* History Messages */}
|
||||
<div className="space-y-2">
|
||||
<div className="text-sm font-medium">{t('documentPanel.pipelineStatus.historyMessages')}:</div>
|
||||
<div
|
||||
<div
|
||||
ref={historyRef}
|
||||
onScroll={handleScroll}
|
||||
className="font-mono text-sm rounded-md bg-zinc-800 text-zinc-100 p-3 overflow-y-auto min-h-[7.5em] max-h-[40vh]"
|
||||
|
@@ -118,7 +118,7 @@ export default function DocumentManager() {
|
||||
const fetchDocuments = useCallback(async () => {
|
||||
try {
|
||||
const docs = await getDocuments()
|
||||
|
||||
|
||||
// Get new status counts (treat null as all zeros)
|
||||
const newStatusCounts = {
|
||||
processed: docs?.statuses?.processed?.length || 0,
|
||||
|
Reference in New Issue
Block a user