From 9de08448f00b77168651315bab9b4987d6632938 Mon Sep 17 00:00:00 2001 From: asafg Date: Wed, 4 Dec 2024 14:56:09 +0200 Subject: [PATCH] fix: Added logs of env --- examples/studio/conversational-rag/rag-engine.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/examples/studio/conversational-rag/rag-engine.ts b/examples/studio/conversational-rag/rag-engine.ts index a899b2a..28b08f0 100644 --- a/examples/studio/conversational-rag/rag-engine.ts +++ b/examples/studio/conversational-rag/rag-engine.ts @@ -55,10 +55,9 @@ async function uploadGetUpdateDelete(fileInput, path) { console.log('Starting file deletion...'); await client.files.delete(uploadFileResponse.fileId); console.log('✓ File deletion completed'); - + // Add buffer time between operations await sleep(2000); - } catch (error) { console.error('❌ Error in uploadGetUpdateDelete:', error); throw error; @@ -76,6 +75,15 @@ const isBrowser = typeof window !== 'undefined' && typeof window.document !== 'u if (isBrowser) { console.log('Cannot run upload examples in Browser environment'); } else { + /* Log environment details */ + console.log('=== Environment Information ==='); + console.log(`Node.js Version: ${process.version}`); + console.log(`Platform: ${process.platform}`); + console.log(`Architecture: ${process.arch}`); + console.log(`Process ID: ${process.pid}`); + console.log(`Current Working Directory: ${process.cwd()}`); + console.log('===========================\n'); + /* Run all operations sequentially */ (async () => { try {