arcvision 0.1.14 → 0.1.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +3 -2
- package/package.json +1 -1
- package/src/index.js +3 -2
package/dist/index.js
CHANGED
|
@@ -56715,7 +56715,7 @@ async function uploadToDatabase(jsonData) {
|
|
|
56715
56715
|
try {
|
|
56716
56716
|
console.log(chalk.blue(`Uploading to ${API_URL}/api/upload...`));
|
|
56717
56717
|
const controller = new AbortController();
|
|
56718
|
-
const timeoutId = setTimeout(() => controller.abort(),
|
|
56718
|
+
const timeoutId = setTimeout(() => controller.abort(), 6e4);
|
|
56719
56719
|
const response = await fetch(`${API_URL}/api/upload`, {
|
|
56720
56720
|
method: "POST",
|
|
56721
56721
|
headers: {
|
|
@@ -56806,8 +56806,9 @@ program.command("scan").description("Scan the current directory and generate arc
|
|
|
56806
56806
|
console.log(chalk.green("Scan complete!"));
|
|
56807
56807
|
const blastRadiusInfo = analyzeBlastRadius(map);
|
|
56808
56808
|
if (blastRadiusInfo && blastRadiusInfo.blast_radius > 0) {
|
|
56809
|
+
const totalFiles = map.nodes.length;
|
|
56809
56810
|
console.log(`
|
|
56810
|
-
\u26A0\uFE0F
|
|
56811
|
+
\u26A0\uFE0F ${blastRadiusInfo.file} at the center of the system (blast radius: ${blastRadiusInfo.blast_radius} out of ${totalFiles}). This file represents a single point of systemic failure. Changes here may affect many parts of the system.`);
|
|
56811
56812
|
} else {
|
|
56812
56813
|
console.log("\nNo high-risk files detected based on import dependencies.");
|
|
56813
56814
|
}
|
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -88,7 +88,7 @@ async function uploadToDatabase(jsonData) {
|
|
|
88
88
|
|
|
89
89
|
// Add timeout to fetch request
|
|
90
90
|
const controller = new AbortController();
|
|
91
|
-
const timeoutId = setTimeout(() => controller.abort(),
|
|
91
|
+
const timeoutId = setTimeout(() => controller.abort(), 60000); // 60 second timeout
|
|
92
92
|
|
|
93
93
|
const response = await fetch(`${API_URL}/api/upload`, {
|
|
94
94
|
method: 'POST',
|
|
@@ -205,7 +205,8 @@ program
|
|
|
205
205
|
// Analyze and print blast radius insight
|
|
206
206
|
const blastRadiusInfo = analyzeBlastRadius(map);
|
|
207
207
|
if (blastRadiusInfo && blastRadiusInfo.blast_radius > 0) {
|
|
208
|
-
|
|
208
|
+
const totalFiles = map.nodes.length;
|
|
209
|
+
console.log(`\n⚠️ ${blastRadiusInfo.file} at the center of the system (blast radius: ${blastRadiusInfo.blast_radius} out of ${totalFiles}). This file represents a single point of systemic failure. Changes here may affect many parts of the system.`);
|
|
209
210
|
} else {
|
|
210
211
|
console.log('\nNo high-risk files detected based on import dependencies.');
|
|
211
212
|
}
|