mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-09-20 21:33:56 +02:00
Fix Json Output Issue and Fix miscount of new docs per Index Attempt (#641)
This commit is contained in:
@@ -46,7 +46,7 @@ export function IndexingAttemptsTable({ ccPair }: { ccPair: CCPairFullInfo }) {
|
||||
size="xs"
|
||||
/>
|
||||
</TableCell>
|
||||
<TableCell>{indexAttempt.num_docs_indexed}</TableCell>
|
||||
<TableCell>{indexAttempt.new_docs_indexed}</TableCell>
|
||||
<TableCell>
|
||||
<Text className="flex flex-wrap whitespace-normal">
|
||||
{indexAttempt.error_msg || "-"}
|
||||
|
@@ -44,12 +44,12 @@ function CCPairIndexingStatusDisplay({
|
||||
errorMsg={ccPairsIndexingStatus?.latest_index_attempt?.error_msg}
|
||||
size="xs"
|
||||
/>
|
||||
{ccPairsIndexingStatus?.latest_index_attempt?.num_docs_indexed &&
|
||||
{ccPairsIndexingStatus?.latest_index_attempt?.new_docs_indexed &&
|
||||
ccPairsIndexingStatus?.latest_index_attempt?.status === "in_progress" ? (
|
||||
<div className="text-xs mt-0.5">
|
||||
<div>
|
||||
<i>Current Run:</i>{" "}
|
||||
{ccPairsIndexingStatus.latest_index_attempt.num_docs_indexed} docs
|
||||
{ccPairsIndexingStatus.latest_index_attempt.new_docs_indexed} docs
|
||||
indexed
|
||||
</div>
|
||||
<div>
|
||||
|
@@ -7,7 +7,7 @@ export const getDocsProcessedPerMinute = (
|
||||
!indexAttempt ||
|
||||
!indexAttempt.time_started ||
|
||||
!indexAttempt.time_updated ||
|
||||
indexAttempt.num_docs_indexed === 0
|
||||
indexAttempt.new_docs_indexed === 0
|
||||
) {
|
||||
return null;
|
||||
}
|
||||
@@ -22,5 +22,5 @@ export const getDocsProcessedPerMinute = (
|
||||
if (seconds < 10) {
|
||||
return null;
|
||||
}
|
||||
return (indexAttempt.num_docs_indexed / seconds) * 60;
|
||||
return (indexAttempt.new_docs_indexed / seconds) * 60;
|
||||
};
|
||||
|
@@ -131,7 +131,7 @@ export interface GoogleSitesConfig {
|
||||
export interface IndexAttemptSnapshot {
|
||||
id: number;
|
||||
status: ValidStatuses | null;
|
||||
num_docs_indexed: number;
|
||||
new_docs_indexed: number;
|
||||
error_msg: string | null;
|
||||
time_started: string | null;
|
||||
time_updated: string;
|
||||
|
Reference in New Issue
Block a user