diff --git a/.vscode/launch.json b/.vscode/launch.json
index 28269b98d..2010f1d3e 100644
--- a/.vscode/launch.json
+++ b/.vscode/launch.json
@@ -18,7 +18,7 @@
"outFiles": [
"${workspaceFolder}/dist/*.js"
],
- "preLaunchTask": "npm: webpack-dev"
+ "preLaunchTask": "npm: webpack-dev",
},
{
"name": "Launch Tests",
diff --git a/CHANGELOG.md b/CHANGELOG.md
index d6cab784d..9056dddee 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,6 @@
# Change Log
+## 0.7.3 (Oct 10th 2023)
+- enhancement - Support for Golang. See [#645](https://github.com/fabric8-analytics/fabric8-analytics-vscode-extension/pull/645)
## 0.7.0 (Sep 11th 2023)
- fixes - Improved overall performance and stability with the analysis report.
- informational - Alpha release of the new Red Hat Dependency Analytics (RHDA) extension.
diff --git a/README.md b/README.md
index 84b0ab8f6..c07c1ec1b 100644
--- a/README.md
+++ b/README.md
@@ -1,8 +1,8 @@
# Red Hat Dependency Analytics
[![Visual Studio Marketplace](https://vsmarketplacebadges.dev/version/redhat.fabric8-analytics.svg)](https://marketplace.visualstudio.com/items?itemName=redhat.fabric8-analytics)
-![CI Build](https://github.com/fabric8-analytics/fabric8-analytics-vscode-extension/workflows/Tests/badge.svg?branch=master)
-[![codecov](https://codecov.io/gh/fabric8-analytics/fabric8-analytics-vscode-extension/branch/master/graph/badge.svg?token=rHIO4KNlJ0)](https://codecov.io/gh/fabric8-analytics/fabric8-analytics-vscode-extension)
+![CI](https://github.com/fabric8-analytics/fabric8-analytics-vscode-extension/workflows/CI/badge.svg?branch=master)
+[![Codecov](https://codecov.io/gh/fabric8-analytics/fabric8-analytics-vscode-extension/branch/master/graph/badge.svg?token=rHIO4KNlJ0)](https://codecov.io/gh/fabric8-analytics/fabric8-analytics-vscode-extension)
Red Hat's Dependency Analytics (RHDA) extension gives you awareness to security concerns within your software supply chain while you build your application.
The Dependency Analytics extension uses the Snyk REST API to query [Snyk's Vulnerability Database](https://snyk.io/product/vulnerability-database/) for the most up-to-date vulnerability information available.
@@ -13,7 +13,7 @@ Snyk uses industry-leading security intelligence by pulling from many data sourc
Dependency Analytics only accesses your manifest files to analyze your application dependencies before displaying the vulnerability report.
**IMPORTANT:**
-
Currently, Dependency Analytics only supports projects that use Maven (`mvn`), and Node ecosystems (`npm`).
+
Currently, Dependency Analytics only supports projects that use Maven (`mvn`), Node (`npm`) and Golang (`go`) ecosystems.
In future releases, Red Hat plans to support other programming languages.
##### Table of Contents
@@ -32,12 +32,13 @@ In future releases, Red Hat plans to support other programming languages.
- For Maven projects, analyzing a `pom.xml` file, you must have the `mvn` binary in your system’s `PATH` environment.
- For Node projects, analyzing a `package.json` file, you must have the `npm` binary in your system’s `PATH` environment.
+- For Golang projects, analyzing a `go.mod` file, you must have the `go` binary in your system’s `PATH` environment.
**IMPORTANT:**
Visual Studio Code by default executes binaries directly in a terminal found in your system's `PATH` environment.
You can configure Visual Studio Code to look somewhere else to run the necessary binaries.
You can configure this by accessing the [extension settings](https://code.visualstudio.com/docs/getstarted/settings).
-Click the **Workspace** tab, search for the word _executable_, and specify the absolute path to the binary file you want to use for Maven or Node.
+Click the **Workspace** tab, search for the word _executable_, and specify the absolute path to the binary file you want to use for Maven, Node or Golang.
**Procedure**
@@ -94,7 +95,7 @@ The default path is `/tmp/redhatDependencyAnalyticsReport.html`.
## Features
- **Component analysis**
-
Upon opening a manifest file, such as a `pom.xml` or `package.json` file, a scan starts the analysis process.
+
Upon opening a manifest file, such as a `pom.xml`, `package.json` or `go.mod` file, a scan starts the analysis process.
The scan provides immediate inline feedback on detected security vulnerabilities for your application's dependencies.
Such dependencies are appropriately underlined in red, and hovering over it gives you a short summary of the security concern.
The summary has the full package name, version number, the amount of known security vulnerabilities, and the highest severity status of said vulnerabilities.
@@ -141,6 +142,14 @@ The default path is `/tmp/redhatDependencyAnalyticsReport.html`.
}
```
+ If you wish to ignore vulnerabilities for a dependency in a `go.mod` file, you must add `exhortignore` as a comment against the dependency in the manifest file.
+ For example:
+ ```
+ require (
+ golang.org/x/sys v1.6.7 // exhortignore
+ )
+ ```
+
- **Excluding developmental or test dependencies**
Red Hat Dependency Analytics does not analyze dependencies marked as `dev` or `test`, these dependencies are ignored.
For example, setting `test` in the `scope` tag within a `pom.xml` file:
@@ -177,6 +186,16 @@ The default path is `/tmp/redhatDependencyAnalyticsReport.html`.
}
```
+ For example, setting `exclude` attributte in the `go.mod` file:
+
+ ```
+ exclude golang.org/x/sys v1.6.7
+
+ exclude (
+ golang.org/x/sys v1.6.7
+ )
+ ```
+
- **Red Hat Dependency Analytics report**
The Red Hat Dependency Analytics report is a temporary HTML file that exist if the **Red Hat Dependency Analytics Report** tab remains open.
Closing the tab removes the temporary HTML file.
diff --git a/images/screenshots/extension-workspace-settings.png b/images/screenshots/extension-workspace-settings.png
index 7c8383984..f78f80099 100644
Binary files a/images/screenshots/extension-workspace-settings.png and b/images/screenshots/extension-workspace-settings.png differ
diff --git a/package-lock.json b/package-lock.json
index 36221bf08..80c87719d 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -9,9 +9,9 @@
"version": "0.7.2",
"license": "Apache-2.0",
"dependencies": {
- "@fabric8-analytics/fabric8-analytics-lsp-server": "^0.7.1-ea.4",
+ "@fabric8-analytics/fabric8-analytics-lsp-server": "^0.7.1-ea.10",
"@redhat-developer/vscode-redhat-telemetry": "^0.6.1",
- "@RHEcosystemAppEng/exhort-javascript-api": "^0.0.2-alpha.4",
+ "@RHEcosystemAppEng/exhort-javascript-api": "^0.0.2-ea.32",
"fs": "^0.0.1-security",
"path": "^0.12.7",
"vscode-languageclient": "^8.1.0"
@@ -134,31 +134,31 @@
}
},
"node_modules/@babel/compat-data": {
- "version": "7.22.9",
- "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.22.9.tgz",
- "integrity": "sha512-5UamI7xkUcJ3i9qVDS+KFDEK8/7oJ55/sJMB1Ge7IEapr7KfdfV/HErR+koZwOfd+SgtFKOKRhRakdg++DcJpQ==",
+ "version": "7.22.20",
+ "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.22.20.tgz",
+ "integrity": "sha512-BQYjKbpXjoXwFW5jGqiizJQQT/aC7pFm9Ok1OWssonuguICi264lbgMzRp2ZMmRSlfkX6DsWDDcsrctK8Rwfiw==",
"dev": true,
"engines": {
"node": ">=6.9.0"
}
},
"node_modules/@babel/core": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.22.15.tgz",
- "integrity": "sha512-PtZqMmgRrvj8ruoEOIwVA3yoF91O+Hgw9o7DAUTNBA6Mo2jpu31clx9a7Nz/9JznqetTR6zwfC4L3LAjKQXUwA==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.23.0.tgz",
+ "integrity": "sha512-97z/ju/Jy1rZmDxybphrBuI+jtJjFVoz7Mr9yUQVVVi+DNZE333uFQeMOqcCIy1x3WYBIbWftUSLmbNXNT7qFQ==",
"dev": true,
"dependencies": {
"@ampproject/remapping": "^2.2.0",
"@babel/code-frame": "^7.22.13",
- "@babel/generator": "^7.22.15",
+ "@babel/generator": "^7.23.0",
"@babel/helper-compilation-targets": "^7.22.15",
- "@babel/helper-module-transforms": "^7.22.15",
- "@babel/helpers": "^7.22.15",
- "@babel/parser": "^7.22.15",
+ "@babel/helper-module-transforms": "^7.23.0",
+ "@babel/helpers": "^7.23.0",
+ "@babel/parser": "^7.23.0",
"@babel/template": "^7.22.15",
- "@babel/traverse": "^7.22.15",
- "@babel/types": "^7.22.15",
- "convert-source-map": "^1.7.0",
+ "@babel/traverse": "^7.23.0",
+ "@babel/types": "^7.23.0",
+ "convert-source-map": "^2.0.0",
"debug": "^4.1.0",
"gensync": "^1.0.0-beta.2",
"json5": "^2.2.3",
@@ -172,6 +172,12 @@
"url": "https://opencollective.com/babel"
}
},
+ "node_modules/@babel/core/node_modules/convert-source-map": {
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz",
+ "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==",
+ "dev": true
+ },
"node_modules/@babel/core/node_modules/semver": {
"version": "6.3.1",
"resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz",
@@ -182,12 +188,12 @@
}
},
"node_modules/@babel/generator": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.22.15.tgz",
- "integrity": "sha512-Zu9oWARBqeVOW0dZOjXc3JObrzuqothQ3y/n1kUtrjCoCPLkXUwMvOo/F/TCfoHMbWIFlWwpZtkZVb9ga4U2pA==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz",
+ "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==",
"dev": true,
"dependencies": {
- "@babel/types": "^7.22.15",
+ "@babel/types": "^7.23.0",
"@jridgewell/gen-mapping": "^0.3.2",
"@jridgewell/trace-mapping": "^0.3.17",
"jsesc": "^2.5.1"
@@ -222,22 +228,22 @@
}
},
"node_modules/@babel/helper-environment-visitor": {
- "version": "7.22.5",
- "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.5.tgz",
- "integrity": "sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==",
+ "version": "7.22.20",
+ "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz",
+ "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==",
"dev": true,
"engines": {
"node": ">=6.9.0"
}
},
"node_modules/@babel/helper-function-name": {
- "version": "7.22.5",
- "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.22.5.tgz",
- "integrity": "sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz",
+ "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==",
"dev": true,
"dependencies": {
- "@babel/template": "^7.22.5",
- "@babel/types": "^7.22.5"
+ "@babel/template": "^7.22.15",
+ "@babel/types": "^7.23.0"
},
"engines": {
"node": ">=6.9.0"
@@ -268,16 +274,16 @@
}
},
"node_modules/@babel/helper-module-transforms": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.22.15.tgz",
- "integrity": "sha512-l1UiX4UyHSFsYt17iQ3Se5pQQZZHa22zyIXURmvkmLCD4t/aU+dvNWHatKac/D9Vm9UES7nvIqHs4jZqKviUmQ==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.23.0.tgz",
+ "integrity": "sha512-WhDWw1tdrlT0gMgUJSlX0IQvoO1eN279zrAUbVB+KpV2c3Tylz8+GnKOLllCS6Z/iZQEyVYxhZVUdPTqs2YYPw==",
"dev": true,
"dependencies": {
- "@babel/helper-environment-visitor": "^7.22.5",
+ "@babel/helper-environment-visitor": "^7.22.20",
"@babel/helper-module-imports": "^7.22.15",
"@babel/helper-simple-access": "^7.22.5",
"@babel/helper-split-export-declaration": "^7.22.6",
- "@babel/helper-validator-identifier": "^7.22.15"
+ "@babel/helper-validator-identifier": "^7.22.20"
},
"engines": {
"node": ">=6.9.0"
@@ -320,9 +326,9 @@
}
},
"node_modules/@babel/helper-validator-identifier": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.15.tgz",
- "integrity": "sha512-4E/F9IIEi8WR94324mbDUMo074YTheJmd7eZF5vITTeYchqAi6sYXRLHUVsmkdmY4QjfKTcB2jB7dVP3NaBElQ==",
+ "version": "7.22.20",
+ "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz",
+ "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==",
"dev": true,
"engines": {
"node": ">=6.9.0"
@@ -338,26 +344,26 @@
}
},
"node_modules/@babel/helpers": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.22.15.tgz",
- "integrity": "sha512-7pAjK0aSdxOwR+CcYAqgWOGy5dcfvzsTIfFTb2odQqW47MDfv14UaJDY6eng8ylM2EaeKXdxaSWESbkmaQHTmw==",
+ "version": "7.23.1",
+ "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.23.1.tgz",
+ "integrity": "sha512-chNpneuK18yW5Oxsr+t553UZzzAs3aZnFm4bxhebsNTeshrC95yA7l5yl7GBAG+JG1rF0F7zzD2EixK9mWSDoA==",
"dev": true,
"dependencies": {
"@babel/template": "^7.22.15",
- "@babel/traverse": "^7.22.15",
- "@babel/types": "^7.22.15"
+ "@babel/traverse": "^7.23.0",
+ "@babel/types": "^7.23.0"
},
"engines": {
"node": ">=6.9.0"
}
},
"node_modules/@babel/highlight": {
- "version": "7.22.13",
- "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.13.tgz",
- "integrity": "sha512-C/BaXcnnvBCmHTpz/VGZ8jgtE2aYlW4hxDhseJAWZb7gqGM/qtCK6iZUb0TyKFf7BOUsBH7Q7fkRsDRhg1XklQ==",
+ "version": "7.22.20",
+ "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz",
+ "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==",
"dev": true,
"dependencies": {
- "@babel/helper-validator-identifier": "^7.22.5",
+ "@babel/helper-validator-identifier": "^7.22.20",
"chalk": "^2.4.2",
"js-tokens": "^4.0.0"
},
@@ -428,9 +434,9 @@
}
},
"node_modules/@babel/parser": {
- "version": "7.22.16",
- "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.22.16.tgz",
- "integrity": "sha512-+gPfKv8UWeKKeJTUxe59+OobVcrYHETCsORl61EmSkmgymguYk/X5bp7GuUIXaFsc6y++v8ZxPsLSSuujqDphA==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz",
+ "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==",
"dev": true,
"bin": {
"parser": "bin/babel-parser.js"
@@ -454,19 +460,19 @@
}
},
"node_modules/@babel/traverse": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.22.15.tgz",
- "integrity": "sha512-DdHPwvJY0sEeN4xJU5uRLmZjgMMDIvMPniLuYzUVXj/GGzysPl0/fwt44JBkyUIzGJPV8QgHMcQdQ34XFuKTYQ==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.0.tgz",
+ "integrity": "sha512-t/QaEvyIoIkwzpiZ7aoSKK8kObQYeF7T2v+dazAYCb8SXtp58zEVkWW7zAnju8FNKNdr4ScAOEDmMItbyOmEYw==",
"dev": true,
"dependencies": {
"@babel/code-frame": "^7.22.13",
- "@babel/generator": "^7.22.15",
- "@babel/helper-environment-visitor": "^7.22.5",
- "@babel/helper-function-name": "^7.22.5",
+ "@babel/generator": "^7.23.0",
+ "@babel/helper-environment-visitor": "^7.22.20",
+ "@babel/helper-function-name": "^7.23.0",
"@babel/helper-hoist-variables": "^7.22.5",
"@babel/helper-split-export-declaration": "^7.22.6",
- "@babel/parser": "^7.22.15",
- "@babel/types": "^7.22.15",
+ "@babel/parser": "^7.23.0",
+ "@babel/types": "^7.23.0",
"debug": "^4.1.0",
"globals": "^11.1.0"
},
@@ -475,13 +481,13 @@
}
},
"node_modules/@babel/types": {
- "version": "7.22.15",
- "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.22.15.tgz",
- "integrity": "sha512-X+NLXr0N8XXmN5ZsaQdm9U2SSC3UbIYq/doL++sueHOTisgZHoKaQtZxGuV2cUPQHMfjKEfg/g6oy7Hm6SKFtA==",
+ "version": "7.23.0",
+ "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz",
+ "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==",
"dev": true,
"dependencies": {
"@babel/helper-string-parser": "^7.22.5",
- "@babel/helper-validator-identifier": "^7.22.15",
+ "@babel/helper-validator-identifier": "^7.22.20",
"to-fast-properties": "^2.0.0"
},
"engines": {
@@ -549,12 +555,12 @@
}
},
"node_modules/@fabric8-analytics/fabric8-analytics-lsp-server": {
- "version": "0.7.1-ea.4",
- "resolved": "https://npm.pkg.github.com/download/@fabric8-analytics/fabric8-analytics-lsp-server/0.7.1-ea.4/c9b256300d889d81297ee3d33f4060310e03d494",
- "integrity": "sha512-KVBH38bkZB7Ac9qJiWLECYEQWNsZ1/HblsV74nMtdZGsfT7moqLZ0zOia4aXchUlKAzOhT8xQcm6ewfSVW+XHw==",
+ "version": "0.7.1-ea.10",
+ "resolved": "https://npm.pkg.github.com/download/@fabric8-analytics/fabric8-analytics-lsp-server/0.7.1-ea.10/ab755d0128eb812c2113162e5b6dc6dfb4021a61",
+ "integrity": "sha512-KdhJL75NFzWGG1DrEVvdYnfGa5JEs+mATMP/jjN7o/7+VYx4+luFEUdGIrrmhq3dMiOU7avbZz30Lk+KQHXF1g==",
"license": "Apache-2.0",
"dependencies": {
- "@RHEcosystemAppEng/exhort-javascript-api": "^0.0.2-alpha.4",
+ "@RHEcosystemAppEng/exhort-javascript-api": "^0.0.2-ea.32",
"@xml-tools/ast": "^5.0.5",
"@xml-tools/parser": "^1.0.11",
"compare-versions": "^6.0.0-rc.1",
@@ -821,9 +827,9 @@
}
},
"node_modules/@RHEcosystemAppEng/exhort-javascript-api": {
- "version": "0.0.2-alpha.4",
- "resolved": "https://npm.pkg.github.com/download/@RHEcosystemAppEng/exhort-javascript-api/0.0.2-alpha.4/cc81bf68bc231f6cb7cf81bf7c63ba144a8537e3",
- "integrity": "sha512-Lc6QPoedTB7uai4II+ZgbknI50A3mWV6boHQFFqkL+HIDUz/Hfj4IyaUTdbM2MASIXu8jjGFUNtDdYhLV1l+Xw==",
+ "version": "0.0.2-ea.32",
+ "resolved": "https://npm.pkg.github.com/download/@RHEcosystemAppEng/exhort-javascript-api/0.0.2-ea.32/1f79abff8138c7bfb663b1aeb49e3328f731b0d1",
+ "integrity": "sha512-4Bc3oeZsu9JbE3+SN2NxtPcSudsCdQ+x8yUfIwW+s1U/6oviCkyWBUSreoPqa/fHt3uk9bHJy1FJ+NLmVlb2Rw==",
"license": "Apache-2.0",
"dependencies": {
"@cyclonedx/cyclonedx-library": "^4.0.0",
@@ -941,9 +947,9 @@
"dev": true
},
"node_modules/@types/eslint": {
- "version": "8.44.2",
- "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.44.2.tgz",
- "integrity": "sha512-sdPRb9K6iL5XZOmBubg8yiFp5yS/JdUDQsq5e6h95km91MCYMuvp7mh1fjPEYUhvHepKpZOjnEaMBR4PxjWDzg==",
+ "version": "8.44.3",
+ "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.44.3.tgz",
+ "integrity": "sha512-iM/WfkwAhwmPff3wZuPLYiHX18HI24jU8k1ZSH7P8FHwxTjZ2P6CoX2wnF43oprR+YXJM6UUxATkNvyv/JHd+g==",
"dev": true,
"dependencies": {
"@types/estree": "*",
@@ -951,9 +957,9 @@
}
},
"node_modules/@types/eslint-scope": {
- "version": "3.7.4",
- "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.4.tgz",
- "integrity": "sha512-9K4zoImiZc3HlIp6AVUDE4CWYx22a+lhSZMYNpbjW04+YF0KWj4pJXnEMjdnFTiQibFFmElcsasJXDbdI/EPhA==",
+ "version": "3.7.5",
+ "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.5.tgz",
+ "integrity": "sha512-JNvhIEyxVW6EoMIFIvj93ZOywYFatlpu9deeH6eSx6PE3WHYvHaQtmHmQeNw7aA81bYGBPPQqdtBm6b1SsQMmA==",
"dev": true,
"dependencies": {
"@types/eslint": "*",
@@ -961,9 +967,9 @@
}
},
"node_modules/@types/estree": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz",
- "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==",
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.2.tgz",
+ "integrity": "sha512-VeiPZ9MMwXjO32/Xu7+OwflfmeoRwkE/qzndw42gGtgJwZopBnzy2gD//NN1+go1mADzkDcqf/KnFRSjTJ8xJA==",
"dev": true
},
"node_modules/@types/glob": {
@@ -977,9 +983,9 @@
}
},
"node_modules/@types/json-schema": {
- "version": "7.0.12",
- "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.12.tgz",
- "integrity": "sha512-Hr5Jfhc9eYOQNPYO5WLDq/n4jqijdHNlDXjuAQkkt+mWdQR+XJToOHrsD4cPaMXpn6KO7y2+wM8AZEs8VpBLVA==",
+ "version": "7.0.13",
+ "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.13.tgz",
+ "integrity": "sha512-RbSSoHliUbnXj3ny0CNFOoxrIDV6SUGyStHsvDqosw6CkdPV8TtWGlfecuK4ToyMEAql6pzNxgCFKanovUzlgQ==",
"dev": true
},
"node_modules/@types/minimatch": {
@@ -989,42 +995,42 @@
"dev": true
},
"node_modules/@types/mocha": {
- "version": "10.0.1",
- "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz",
- "integrity": "sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q==",
+ "version": "10.0.2",
+ "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.2.tgz",
+ "integrity": "sha512-NaHL0+0lLNhX6d9rs+NSt97WH/gIlRHmszXbQ/8/MV/eVcFNdeJ/GYhrFuUc8K7WuPhRhTSdMkCp8VMzhUq85w==",
"dev": true
},
"node_modules/@types/node": {
- "version": "20.5.9",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-20.5.9.tgz",
- "integrity": "sha512-PcGNd//40kHAS3sTlzKB9C9XL4K0sTup8nbG5lC14kzEteTNuAFh9u5nA0o5TWnSG2r/JNPRXFVcHJIIeRlmqQ==",
+ "version": "20.8.3",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-20.8.3.tgz",
+ "integrity": "sha512-jxiZQFpb+NlH5kjW49vXxvxTjeeqlbsnTAdBTKpzEdPs9itay7MscYXz3Fo9VYFEsfQ6LJFitHad3faerLAjCw==",
"dev": true
},
"node_modules/@types/sinon": {
- "version": "10.0.16",
- "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.16.tgz",
- "integrity": "sha512-j2Du5SYpXZjJVJtXBokASpPRj+e2z+VUhCPHmM6WMfe3dpHu6iVKJMU6AiBcMp/XTAYnEj6Wc1trJUWwZ0QaAQ==",
+ "version": "10.0.19",
+ "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.19.tgz",
+ "integrity": "sha512-MWZNGPSchIdDfb5FL+VFi4zHsHbNOTQEgjqFQk7HazXSXwUU9PAX3z9XBqb3AJGYr9YwrtCtaSMsT3brYsN/jQ==",
"dev": true,
"dependencies": {
"@types/sinonjs__fake-timers": "*"
}
},
"node_modules/@types/sinonjs__fake-timers": {
- "version": "8.1.2",
- "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.2.tgz",
- "integrity": "sha512-9GcLXF0/v3t80caGs5p2rRfkB+a8VBGLJZVih6CNFkx8IZ994wiKKLSRs9nuFwk1HevWs/1mnUmkApGrSGsShA==",
+ "version": "8.1.3",
+ "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.3.tgz",
+ "integrity": "sha512-4g+2YyWe0Ve+LBh+WUm1697PD0Kdi6coG1eU0YjQbwx61AZ8XbEpL1zIT6WjuUKrCMCROpEaYQPDjBnDouBVAQ==",
"dev": true
},
"node_modules/@types/vscode": {
- "version": "1.81.0",
- "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.81.0.tgz",
- "integrity": "sha512-YIaCwpT+O2E7WOMq0eCgBEABE++SX3Yl/O02GoMIF2DO3qAtvw7m6BXFYsxnc6XyzwZgh6/s/UG78LSSombl2w==",
+ "version": "1.83.0",
+ "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.83.0.tgz",
+ "integrity": "sha512-3mUtHqLAVz9hegut9au4xehuBrzRE3UJiQMpoEHkNl6XHliihO7eATx2BMHs0odsmmrwjJrlixx/Pte6M3ygDQ==",
"dev": true
},
"node_modules/@vscode/test-electron": {
- "version": "2.3.4",
- "resolved": "https://registry.npmjs.org/@vscode/test-electron/-/test-electron-2.3.4.tgz",
- "integrity": "sha512-eWzIqXMhvlcoXfEFNWrVu/yYT5w6De+WZXR/bafUQhAp8+8GkQo95Oe14phwiRUPv8L+geAKl/QM2+PoT3YW3g==",
+ "version": "2.3.5",
+ "resolved": "https://registry.npmjs.org/@vscode/test-electron/-/test-electron-2.3.5.tgz",
+ "integrity": "sha512-lAW7nQ0HuPqJnGJrtCzEKZCICtRizeP6qNanyCrjmdCOAAWjX3ixiG8RVPwqsYPQBWLPgYuE12qQlwXsOR/2fQ==",
"dev": true,
"dependencies": {
"http-proxy-agent": "^4.0.1",
@@ -1555,9 +1561,9 @@
"integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q=="
},
"node_modules/axios": {
- "version": "1.5.0",
- "resolved": "https://registry.npmjs.org/axios/-/axios-1.5.0.tgz",
- "integrity": "sha512-D4DdjDo5CY50Qms0qGQTTw6Q44jl7zRwY7bthds06pUGfChBCTcQs+N743eFWGEd6pRTMd6A+I87aWyFV5wiZQ==",
+ "version": "1.5.1",
+ "resolved": "https://registry.npmjs.org/axios/-/axios-1.5.1.tgz",
+ "integrity": "sha512-Q28iYCWzNHjAm+yEAot5QaAMxhMghWLFVf7rRdwhUI+c2jix2DUXjAHXVi+s1ibs3mjPO/cCgbA++3BjD0vP/A==",
"dependencies": {
"follow-redirects": "^1.15.0",
"form-data": "^4.0.0",
@@ -1616,9 +1622,9 @@
"dev": true
},
"node_modules/browserslist": {
- "version": "4.21.10",
- "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.21.10.tgz",
- "integrity": "sha512-bipEBdZfVH5/pwrvqc+Ub0kUPVfGUhlKxbvfD+z1BDnPEO/X98ruXGA1WP5ASpAFKan7Qr6j736IacbZQuAlKQ==",
+ "version": "4.22.1",
+ "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.22.1.tgz",
+ "integrity": "sha512-FEVc202+2iuClEhZhrWy6ZiAcRLvNMyYcxZ8raemul1DYVOVdFsbqckWLdsixQZCpJlwe77Z3UTalE7jsjnKfQ==",
"dev": true,
"funding": [
{
@@ -1635,10 +1641,10 @@
}
],
"dependencies": {
- "caniuse-lite": "^1.0.30001517",
- "electron-to-chromium": "^1.4.477",
+ "caniuse-lite": "^1.0.30001541",
+ "electron-to-chromium": "^1.4.535",
"node-releases": "^2.0.13",
- "update-browserslist-db": "^1.0.11"
+ "update-browserslist-db": "^1.0.13"
},
"bin": {
"browserslist": "cli.js"
@@ -1696,9 +1702,9 @@
}
},
"node_modules/caniuse-lite": {
- "version": "1.0.30001528",
- "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001528.tgz",
- "integrity": "sha512-0Db4yyjR9QMNlsxh+kKWzQtkyflkG/snYheSzkjmvdEtEXB1+jt7A2HmSEiO6XIJPIbo92lHNGNySvE5pZcs5Q==",
+ "version": "1.0.30001546",
+ "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001546.tgz",
+ "integrity": "sha512-zvtSJwuQFpewSyRrI3AsftF6rM0X80mZkChIt1spBGEvRglCrjTniXvinc8JKRoqTwXAgvqTImaN9igfSMtUBw==",
"dev": true,
"funding": [
{
@@ -1716,18 +1722,18 @@
]
},
"node_modules/chai": {
- "version": "4.3.8",
- "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.8.tgz",
- "integrity": "sha512-vX4YvVVtxlfSZ2VecZgFUTU5qPCYsobVI2O9FmwEXBhDigYGQA6jRXCycIs1yJnnWbZ6/+a2zNIF5DfVCcJBFQ==",
+ "version": "4.3.10",
+ "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.10.tgz",
+ "integrity": "sha512-0UXG04VuVbruMUYbJ6JctvH0YnC/4q3/AkT18q4NaITo91CUm0liMS9VqzT9vZhVQ/1eqPanMWjBM+Juhfb/9g==",
"dev": true,
"dependencies": {
"assertion-error": "^1.1.0",
- "check-error": "^1.0.2",
- "deep-eql": "^4.1.2",
- "get-func-name": "^2.0.0",
- "loupe": "^2.3.1",
+ "check-error": "^1.0.3",
+ "deep-eql": "^4.1.3",
+ "get-func-name": "^2.0.2",
+ "loupe": "^2.3.6",
"pathval": "^1.1.1",
- "type-detect": "^4.0.5"
+ "type-detect": "^4.0.8"
},
"engines": {
"node": ">=4"
@@ -1771,10 +1777,13 @@
}
},
"node_modules/check-error": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz",
- "integrity": "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==",
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.3.tgz",
+ "integrity": "sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg==",
"dev": true,
+ "dependencies": {
+ "get-func-name": "^2.0.2"
+ },
"engines": {
"node": "*"
}
@@ -2116,9 +2125,9 @@
}
},
"node_modules/electron-to-chromium": {
- "version": "1.4.510",
- "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.510.tgz",
- "integrity": "sha512-xPfLIPFcN/WLXBpQ/K4UgE98oUBO5Tia6BD4rkSR0wE7ep/PwBVlgvPJQrIBpmJGVAmUzwPKuDbVt9XV6+uC2g==",
+ "version": "1.4.544",
+ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.544.tgz",
+ "integrity": "sha512-54z7squS1FyFRSUqq/knOFSptjjogLZXbKcYk3B0qkE1KZzvqASwRZnY2KzZQJqIYLVD38XZeoiMRflYSwyO4w==",
"dev": true
},
"node_modules/emoji-regex": {
@@ -2160,9 +2169,9 @@
}
},
"node_modules/es-module-lexer": {
- "version": "1.3.0",
- "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.3.0.tgz",
- "integrity": "sha512-vZK7T0N2CBmBOixhmjdqx2gWVbFZ4DXZ/NyRMZVlJXPa7CyFS+/a4QQsDGDQy9ZfEzxFuNEsMLeQJnKP2p5/JA==",
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.3.1.tgz",
+ "integrity": "sha512-JUFAyicQV9mXc3YRxPnDlrfBKpqt6hUYzz9/boprUJHs4e4KVr3XwOF70doO6gwXUor6EWZJAyWAfKki84t20Q==",
"dev": true
},
"node_modules/es6-error": {
@@ -2356,17 +2365,17 @@
"dev": true
},
"node_modules/fast-xml-parser": {
- "version": "4.2.7",
- "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-4.2.7.tgz",
- "integrity": "sha512-J8r6BriSLO1uj2miOk1NW0YVm8AGOOu3Si2HQp/cSmo6EA4m3fcwu2WKjJ4RK9wMLBtg69y1kS8baDiQBR41Ig==",
+ "version": "4.3.2",
+ "resolved": "https://registry.npmjs.org/fast-xml-parser/-/fast-xml-parser-4.3.2.tgz",
+ "integrity": "sha512-rmrXUXwbJedoXkStenj1kkljNF7ugn5ZjR9FJcwmCfcCbtOMDghPajbc+Tck6vE6F5XsDmx+Pr2le9fw8+pXBg==",
"funding": [
- {
- "type": "paypal",
- "url": "https://paypal.me/naturalintelligence"
- },
{
"type": "github",
"url": "https://github.com/sponsors/NaturalIntelligence"
+ },
+ {
+ "type": "paypal",
+ "url": "https://paypal.me/naturalintelligence"
}
],
"dependencies": {
@@ -2446,9 +2455,9 @@
}
},
"node_modules/follow-redirects": {
- "version": "1.15.2",
- "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz",
- "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==",
+ "version": "1.15.3",
+ "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.3.tgz",
+ "integrity": "sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q==",
"funding": [
{
"type": "individual",
@@ -2565,12 +2574,6 @@
"node": "^8.16.0 || ^10.6.0 || >=11.0.0"
}
},
- "node_modules/function-bind": {
- "version": "1.1.1",
- "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
- "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
- "dev": true
- },
"node_modules/gauge": {
"version": "3.0.2",
"resolved": "https://registry.npmjs.org/gauge/-/gauge-3.0.2.tgz",
@@ -2609,9 +2612,9 @@
}
},
"node_modules/get-func-name": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz",
- "integrity": "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==",
+ "version": "2.0.2",
+ "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.2.tgz",
+ "integrity": "sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==",
"dev": true,
"engines": {
"node": "*"
@@ -2733,13 +2736,10 @@
}
},
"node_modules/has": {
- "version": "1.0.3",
- "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
- "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
+ "version": "1.0.4",
+ "resolved": "https://registry.npmjs.org/has/-/has-1.0.4.tgz",
+ "integrity": "sha512-qdSAmqLF6209RFj4VVItywPMbm3vWylknmB3nvNiUIs72xAimcM8nVYxYr7ncvZq5qzk9MKIZR8ijqD/1QuYjQ==",
"dev": true,
- "dependencies": {
- "function-bind": "^1.1.1"
- },
"engines": {
"node": ">= 0.4.0"
}
@@ -4433,9 +4433,9 @@
}
},
"node_modules/packageurl-js": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/packageurl-js/-/packageurl-js-1.0.2.tgz",
- "integrity": "sha512-fWC4ZPxo80qlh3xN5FxfIoQD3phVY4+EyzTIqyksjhKNDmaicdpxSvkWwIrYTtv9C1/RcUN6pxaTwGmj2NzS6A=="
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/packageurl-js/-/packageurl-js-1.1.1.tgz",
+ "integrity": "sha512-juW4p0J23BvvMj0I9/ORe/Y7TFsNNrEjoZ/h3ToPfU0dvnGXUm6vHtcAINf2Scgv5EqQW7ngTZnkTfgFBPeXNw=="
},
"node_modules/pako": {
"version": "1.0.11",
@@ -4742,9 +4742,9 @@
}
},
"node_modules/rechoir/node_modules/resolve": {
- "version": "1.22.4",
- "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.4.tgz",
- "integrity": "sha512-PXNdCiPqDqeUou+w1C2eTQbNfxKSuMxqTCuvlmmMsk1NWHL5fRrhY6Pl0qEYYc6+QqGClco1Qj8XnjPego4wfg==",
+ "version": "1.22.6",
+ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.6.tgz",
+ "integrity": "sha512-njhxM7mV12JfufShqGy3Rz8j11RPdLy4xi15UurGJeoHLfJpVXKdh3ueuOqbYUcDZnffr6X739JBo5LzyahEsw==",
"dev": true,
"dependencies": {
"is-core-module": "^2.13.0",
@@ -5230,9 +5230,9 @@
}
},
"node_modules/spdx-license-ids": {
- "version": "3.0.13",
- "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.13.tgz",
- "integrity": "sha512-XkD+zwiqXHikFZm4AX/7JSCXA98U5Db4AFd5XUg/+9UNtnH75+Z9KxtpYiJZx36mUDVOwH83pl7yvCer6ewM3w=="
+ "version": "3.0.16",
+ "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.16.tgz",
+ "integrity": "sha512-eWN+LnM3GR6gPu35WxNgbGl8rmY1AEmoMDvL/QD6zYmPWgywxWqJWNdLGT+ke8dKNWrcYgYjPpG5gbTfghP8rw=="
},
"node_modules/sprintf-js": {
"version": "1.0.3",
@@ -5376,9 +5376,9 @@
"optional": true
},
"node_modules/terser": {
- "version": "5.19.4",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.4.tgz",
- "integrity": "sha512-6p1DjHeuluwxDXcuT9VR8p64klWJKo1ILiy19s6C9+0Bh2+NWTX6nD9EPppiER4ICkHDVB1RkVpin/YW2nQn/g==",
+ "version": "5.21.0",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.21.0.tgz",
+ "integrity": "sha512-WtnFKrxu9kaoXuiZFSGrcAvvBqAdmKx0SFNmVNYdJamMu9yyN3I/QF0FbH4QcqJQ+y1CJnzxGIKH0cSj+FGYRw==",
"dev": true,
"dependencies": {
"@jridgewell/source-map": "^0.3.3",
@@ -5507,15 +5507,16 @@
"integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw=="
},
"node_modules/ts-loader": {
- "version": "9.4.4",
- "resolved": "https://registry.npmjs.org/ts-loader/-/ts-loader-9.4.4.tgz",
- "integrity": "sha512-MLukxDHBl8OJ5Dk3y69IsKVFRA/6MwzEqBgh+OXMPB/OD01KQuWPFd1WAQP8a5PeSCAxfnkhiuWqfmFJzJQt9w==",
+ "version": "9.5.0",
+ "resolved": "https://registry.npmjs.org/ts-loader/-/ts-loader-9.5.0.tgz",
+ "integrity": "sha512-LLlB/pkB4q9mW2yLdFMnK3dEHbrBjeZTYguaaIfusyojBgAGf5kF+O6KcWqiGzWqHk0LBsoolrp4VftEURhybg==",
"dev": true,
"dependencies": {
"chalk": "^4.1.0",
"enhanced-resolve": "^5.0.0",
"micromatch": "^4.0.0",
- "semver": "^7.3.4"
+ "semver": "^7.3.4",
+ "source-map": "^0.7.4"
},
"engines": {
"node": ">=12.0.0"
@@ -5525,6 +5526,15 @@
"webpack": "^5.0.0"
}
},
+ "node_modules/ts-loader/node_modules/source-map": {
+ "version": "0.7.4",
+ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.4.tgz",
+ "integrity": "sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==",
+ "dev": true,
+ "engines": {
+ "node": ">= 8"
+ }
+ },
"node_modules/ts-node": {
"version": "10.9.1",
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz",
@@ -5704,9 +5714,9 @@
}
},
"node_modules/tslint/node_modules/resolve": {
- "version": "1.22.4",
- "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.4.tgz",
- "integrity": "sha512-PXNdCiPqDqeUou+w1C2eTQbNfxKSuMxqTCuvlmmMsk1NWHL5fRrhY6Pl0qEYYc6+QqGClco1Qj8XnjPego4wfg==",
+ "version": "1.22.6",
+ "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.6.tgz",
+ "integrity": "sha512-njhxM7mV12JfufShqGy3Rz8j11RPdLy4xi15UurGJeoHLfJpVXKdh3ueuOqbYUcDZnffr6X739JBo5LzyahEsw==",
"dev": true,
"dependencies": {
"is-core-module": "^2.13.0",
@@ -5849,9 +5859,9 @@
}
},
"node_modules/update-browserslist-db": {
- "version": "1.0.11",
- "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.11.tgz",
- "integrity": "sha512-dCwEFf0/oT85M1fHBg4F0jtLwJrutGoHSQXCh7u4o2t1drG+c0a9Flnqww6XUKSfQMPpJBRjU8d4RXB09qtvaA==",
+ "version": "1.0.13",
+ "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.13.tgz",
+ "integrity": "sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg==",
"dev": true,
"funding": [
{
@@ -5907,9 +5917,13 @@
"integrity": "sha512-x00IRNXNy63jwGkJmzPigoySHbaqpNuzKbBOmzK+g2OdZpQ9w+sxCN+VSB3ja7IAge2OP2qpfxTjeNcyjmW1uw=="
},
"node_modules/uuid": {
- "version": "9.0.0",
- "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.0.tgz",
- "integrity": "sha512-MXcSTerfPa4uqyzStbRoTgt5XIe3x5+42+q1sDuy3R5MDk66URdLMOZe5aPX/SQd+kuYAh0FdP/pO28IkQyTeg==",
+ "version": "9.0.1",
+ "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz",
+ "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==",
+ "funding": [
+ "https://github.com/sponsors/broofa",
+ "https://github.com/sponsors/ctavan"
+ ],
"bin": {
"uuid": "dist/bin/uuid"
}
@@ -5981,9 +5995,9 @@
}
},
"node_modules/vscode-languageserver-textdocument": {
- "version": "1.0.8",
- "resolved": "https://registry.npmjs.org/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.8.tgz",
- "integrity": "sha512-1bonkGqQs5/fxGT5UchTgjGVnfysL0O8v1AYMBjqTbWQTFn721zaPGDYFkOKtfDgFiSgXM3KwaG3FMGfW4Ed9Q=="
+ "version": "1.0.11",
+ "resolved": "https://registry.npmjs.org/vscode-languageserver-textdocument/-/vscode-languageserver-textdocument-1.0.11.tgz",
+ "integrity": "sha512-X+8T3GoiwTVlJbicx/sIAF+yuJAqz8VvwJyoMVhwEMoEKE/fkDmrqUgDMyBECcM2A2frVZIUj5HI/ErRXCfOeA=="
},
"node_modules/vscode-languageserver-types": {
"version": "3.17.3",
diff --git a/package.json b/package.json
index eed26a05c..e7fa03781 100644
--- a/package.json
+++ b/package.json
@@ -40,7 +40,8 @@
},
"activationEvents": [
"workspaceContains:**/package.json",
- "workspaceContains:**/pom.xml"
+ "workspaceContains:**/pom.xml",
+ "workspaceContains:**/go.mod"
],
"main": "./dist/extension",
"contributes": {
@@ -83,6 +84,11 @@
"command": "fabric8.stackAnalysisFromPieBtn",
"when": "resourceFilename == package.json",
"group": "navigation"
+ },
+ {
+ "command": "fabric8.stackAnalysisFromPieBtn",
+ "when": "resourceFilename == go.mod",
+ "group": "navigation"
}
],
"explorer/context": [
@@ -93,6 +99,10 @@
{
"command": "fabric8.stackAnalysisFromExplorer",
"when": "resourceFilename == pom.xml"
+ },
+ {
+ "command": "fabric8.stackAnalysisFromExplorer",
+ "when": "resourceFilename == go.mod"
}
],
"editor/context": [
@@ -103,6 +113,10 @@
{
"command": "fabric8.stackAnalysisFromEditor",
"when": "resourceFilename == pom.xml"
+ },
+ {
+ "command": "fabric8.stackAnalysisFromEditor",
+ "when": "resourceFilename == go.mod"
}
],
"commandPalette": [
@@ -168,7 +182,7 @@
"description": "Path to a local file where the Red Hat Dependency Analytics report will be saved.",
"scope": "window"
},
- "maven.executable.path": {
+ "mvn.executable.path": {
"type": "string",
"default": "",
"description": "Specifies absolute path of mvn executable.",
@@ -179,6 +193,12 @@
"default": "",
"description": "Specifies absolute path of npm executable.",
"scope": "window"
+ },
+ "go.executable.path": {
+ "type": "string",
+ "default": "",
+ "description": "Specifies absolute path of go executable.",
+ "scope": "window"
}
}
}
@@ -220,11 +240,11 @@
"webpack-cli": "^5.1.1"
},
"dependencies": {
- "@fabric8-analytics/fabric8-analytics-lsp-server": "^0.7.1-ea.4",
+ "@fabric8-analytics/fabric8-analytics-lsp-server": "^0.7.1-ea.10",
"@redhat-developer/vscode-redhat-telemetry": "^0.6.1",
- "@RHEcosystemAppEng/exhort-javascript-api": "^0.0.2-alpha.4",
+ "@RHEcosystemAppEng/exhort-javascript-api": "^0.0.2-ea.32",
"fs": "^0.0.1-security",
"path": "^0.12.7",
"vscode-languageclient": "^8.1.0"
}
-}
+}
\ No newline at end of file
diff --git a/src/authextension.ts b/src/authextension.ts
index 1c254519b..ec0d72c0c 100644
--- a/src/authextension.ts
+++ b/src/authextension.ts
@@ -2,7 +2,7 @@
import { GlobalState } from './constants';
import { Config } from './config';
-// import { getRedHatService } from '@redhat-developer/vscode-redhat-telemetry/lib';
+import { getRedHatService } from '@redhat-developer/vscode-redhat-telemetry/lib';
export module authextension {
const apiConfig = Config.getApiConfig();
@@ -10,32 +10,27 @@ export module authextension {
setContextData = (apiConfig) => {
process.env['PROVIDE_FULLSTACK_ACTION'] = 'true';
- process.env['UTM_SOURCE'] = 'vscode';
+ process.env['UTM_SOURCE'] = GlobalState.UtmSource;
process.env['SNYK_TOKEN'] = apiConfig.exhortSnykToken;
- process.env['MVN_EXECUTABLE'] = Config.getMavenExecutable();
- process.env['NPM_EXECUTABLE'] = Config.getNodeExecutable();
+ process.env['MVN_EXECUTABLE'] = Config.getMvnExecutable();
+ process.env['NPM_EXECUTABLE'] = Config.getNpmExecutable();
+ process.env['GO_EXECUTABLE'] = Config.getGoExecutable();
process.env['EXHORT_DEV_MODE'] = GlobalState.ExhortDevMode;
};
- // export async function setTelemetryid(context) {
- // const redhatService = await getRedHatService(context);
- // const redhatIdProvider = await redhatService.getIdProvider();
- // const REDHAT_UUID = await redhatIdProvider.getRedHatUUID();
- // process.env['TELEMETRY_ID'] = REDHAT_UUID;
- // }
+ export async function setTelemetryid(context) {
+ const redhatService = await getRedHatService(context);
+ const redhatIdProvider = await redhatService.getIdProvider();
+ const redhatUuid = await redhatIdProvider.getRedHatUUID();
+ process.env['TELEMETRY_ID'] = redhatUuid;
+ }
export const authorize_f8_analytics = async context => {
try {
- // await setTelemetryid(context);
+ await setTelemetryid(context);
setContextData(apiConfig);
- // let uuid = context.globalState.get(GlobalState.UUID);
-
- // if (uuid && uuid !== '') {
- // process.env['UUID'] = uuid;
- // }
-
return true;
} catch (error) {
console.log(error);
diff --git a/src/config.ts b/src/config.ts
index c64fd0103..3ba63aee5 100644
--- a/src/config.ts
+++ b/src/config.ts
@@ -8,17 +8,24 @@ export namespace Config {
return vscode.workspace.getConfiguration('redHatDependencyAnalytics');
}
- export function getMavenExecutable(): string {
+ export function getMvnExecutable(): string {
const mavenPath: string = vscode.workspace
- .getConfiguration('maven.executable')
+ .getConfiguration('mvn.executable')
.get('path');
return mavenPath ? `"${mavenPath}"` : 'mvn';
}
- export function getNodeExecutable(): string {
+ export function getNpmExecutable(): string {
const npmPath: string = vscode.workspace
.getConfiguration('npm.executable')
.get('path');
return npmPath ? `"${npmPath}"` : 'npm';
}
+
+ export function getGoExecutable(): string {
+ const goPath: string = vscode.workspace
+ .getConfiguration('go.executable')
+ .get('path');
+ return goPath ? `${goPath}` : 'go';
+ }
}
diff --git a/src/constants.ts b/src/constants.ts
index 5b41ca601..79cbe5157 100644
--- a/src/constants.ts
+++ b/src/constants.ts
@@ -5,8 +5,8 @@
export enum GlobalState {
// to store the current version string to localStorage
Version = 'fabric8Version',
- // to store the UUID string to localStorage
- // UUID = 'uuid'
+ // to store the UTM source for tracking purposes
+ UtmSource = 'vscode',
// to store the current exhort environment mode
ExhortDevMode = 'false'
}
diff --git a/src/multimanifestmodule.ts b/src/multimanifestmodule.ts
index 2ce1a611e..39a9a5cfd 100644
--- a/src/multimanifestmodule.ts
+++ b/src/multimanifestmodule.ts
@@ -4,134 +4,62 @@ import * as vscode from 'vscode';
import { stackanalysismodule } from './stackanalysismodule';
import { authextension } from './authextension';
-import { StatusMessages } from './constants';
import { DependencyReportPanel } from './dependencyReportPanel';
export module multimanifestmodule {
- /*
- * Needed async function in order to wait for user selection in case of
- * multi root projects
- */
export const redhatDependencyAnalyticsReportFlow = async (context, uri) => {
let workspaceFolder: vscode.WorkspaceFolder;
- if (uri && uri.scheme && uri.scheme === 'file') {
- if (
- uri.fsPath &&
- uri.fsPath.toLowerCase().indexOf('pom.xml') !== -1
- ) {
- workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
- stackanalysismodule.processStackAnalysis(
- context,
- workspaceFolder,
- 'maven',
- uri
- );
- } else if (
- uri.fsPath &&
- uri.fsPath.toLowerCase().indexOf('package.json') !== -1
- ) {
- workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
- stackanalysismodule.processStackAnalysis(
- context,
- workspaceFolder,
- 'npm',
- uri
- );
- // } else if (
- // uri.fsPath &&
- // uri.fsPath.toLowerCase().indexOf('requirements.txt') !== -1
- // ) {
- // workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
- // stackanalysismodule.processStackAnalysis(
- // context,
- // workspaceFolder,
- // 'pypi',
- // uri
- // );
- // } else if (
- // uri.fsPath &&
- // uri.fsPath.toLowerCase().indexOf('go.mod') !== -1
- // ) {
- // workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
- // stackanalysismodule.processStackAnalysis(
- // context,
- // workspaceFolder,
- // 'golang',
- // uri
- // );
- } else {
- vscode.window.showInformationMessage(
- `File ${uri.fsPath} is not supported!!`
- );
- }
+ if (
+ uri.fsPath &&
+ uri.fsPath.toLowerCase().indexOf('pom.xml') !== -1
+ ) {
+ workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
+ stackanalysismodule.processStackAnalysis(
+ context,
+ workspaceFolder,
+ 'maven',
+ uri
+ );
+ } else if (
+ uri.fsPath &&
+ uri.fsPath.toLowerCase().indexOf('package.json') !== -1
+ ) {
+ workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
+ stackanalysismodule.processStackAnalysis(
+ context,
+ workspaceFolder,
+ 'npm',
+ uri
+ );
} else if (
- vscode.workspace.hasOwnProperty('workspaceFolders') &&
- vscode.workspace['workspaceFolders'].length > 1
+ uri.fsPath &&
+ uri.fsPath.toLowerCase().indexOf('go.mod') !== -1
) {
- let workspaceFolder = await vscode.window.showWorkspaceFolderPick({
- placeHolder: 'Pick Workspace Folder...'
- });
- if (workspaceFolder) {
- triggerFullStackAnalysis(context, workspaceFolder);
- } else {
- vscode.window.showInformationMessage(`No Workspace selected.`);
- }
+ workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
+ stackanalysismodule.processStackAnalysis(
+ context,
+ workspaceFolder,
+ 'golang',
+ uri
+ );
+ // } else if (
+ // uri.fsPath &&
+ // uri.fsPath.toLowerCase().indexOf('requirements.txt') !== -1
+ // ) {
+ // workspaceFolder = vscode.workspace.getWorkspaceFolder(uri);
+ // stackanalysismodule.processStackAnalysis(
+ // context,
+ // workspaceFolder,
+ // 'pypi',
+ // uri
+ // );
} else {
- let workspaceFolder = vscode.workspace.workspaceFolders[0];
- triggerFullStackAnalysis(context, workspaceFolder);
+ vscode.window.showInformationMessage(
+ `File ${uri.fsPath} is not supported!!`
+ );
}
};
- export const triggerFullStackAnalysis = (
- context: vscode.ExtensionContext,
- workspaceFolder: vscode.WorkspaceFolder
- ) => {
- const relativePattern = new vscode.RelativePattern(
- workspaceFolder,
- '{pom.xml,**/package.json}'
- );
- vscode.workspace.findFiles(relativePattern, '**/node_modules').then(
- (result: vscode.Uri[]) => {
- if (result && result.length) {
- // Do not create an effective pom if no pom.xml is present
- let effective_pom_skip = true;
- let ecosystem = 'npm';
- let pom_count = 0;
- result.forEach(item => {
- if (item.fsPath.indexOf('pom.xml') >= 0) {
- effective_pom_skip = false;
- pom_count += 1;
- ecosystem = 'maven';
- }
- });
-
- if (!effective_pom_skip && pom_count === 0) {
- vscode.window.showInformationMessage(
- 'Multi ecosystem support is not yet available.'
- );
- return;
- } else {
- stackanalysismodule.processStackAnalysis(
- context,
- workspaceFolder,
- ecosystem
- );
- }
- } else {
- vscode.window.showInformationMessage(
- StatusMessages.NO_SUPPORTED_MANIFEST
- );
- }
- },
- // Other ecosystem flow
- (reason: any) => {
- vscode.window.showInformationMessage(
- StatusMessages.NO_SUPPORTED_MANIFEST
- );
- }
- );
- };
-
export const triggerManifestWs = context => {
return new Promise((resolve, reject) => {
authextension
diff --git a/src/stackanalysismodule.ts b/src/stackanalysismodule.ts
index 7ac7a7bbf..cefb98370 100644
--- a/src/stackanalysismodule.ts
+++ b/src/stackanalysismodule.ts
@@ -5,7 +5,7 @@ import * as path from 'path';
import * as fs from 'fs';
import { Config } from './config';
-import { snykURL, defaultRedhatDependencyAnalyticsReportFilePath, StatusMessages, Titles, GlobalState } from './constants';
+import { snykURL, defaultRedhatDependencyAnalyticsReportFilePath, StatusMessages, Titles } from './constants';
import { multimanifestmodule } from './multimanifestmodule';
import { stackAnalysisServices } from './stackAnalysisService';
import { DependencyReportPanel } from './dependencyReportPanel';
@@ -34,10 +34,15 @@ export module stackanalysismodule {
});
// set up configuration options for the stack analysis request
- const options = {};
- options['EXHORT_MVN_PATH'] = Config.getMavenExecutable();
- options['EXHORT_NPM_PATH'] = Config.getNodeExecutable();
- options['EXHORT_DEV_MODE'] = GlobalState.ExhortDevMode;
+ const options = {
+ 'EXHORT_MVN_PATH': Config.getMvnExecutable(),
+ 'EXHORT_NPM_PATH': Config.getNpmExecutable(),
+ 'EXHORT_GO_PATH': Config.getGoExecutable(),
+ 'EXHORT_DEV_MODE': process.env.EXHORT_DEV_MODE,
+ 'RHDA_TOKEN': process.env.TELEMETRY_ID,
+ 'RHDA_SOURCE': process.env.UTM_SOURCE
+ };
+
if (apiConfig.exhortSnykToken !== '') {
options['EXHORT_SNYK_TOKEN'] = apiConfig.exhortSnykToken;
}
@@ -94,14 +99,15 @@ export module stackanalysismodule {
manifestFilePath = uri
? uri.fsPath
: path.join(workspaceFolder.uri.fsPath, 'package.json');
+
+ } else if (ecosystem === 'golang') {
+ manifestFilePath = uri
+ ? uri.fsPath
+ : path.join(workspaceFolder.uri.fsPath, 'go.mod');
// } else if (ecosystem === 'pypi') {
// manifestFilePath = uri
// ? uri.fsPath.split('requirements.txt')[0]
// : workspaceFolder.uri.fsPath;
- // } else if (ecosystem === 'golang') {
- // manifestFilePath = uri
- // ? uri.fsPath
- // : workspaceFolder.uri.fsPath;
}
stackAnalysisLifeCycle(context, manifestFilePath);
};
@@ -110,7 +116,7 @@ export module stackanalysismodule {
if (DependencyReportPanel.currentPanel) {
DependencyReportPanel.currentPanel.doUpdatePanel('error');
}
- vscode.window.showErrorMessage(err);
+ vscode.window.showErrorMessage(err.message);
};
export const validateSnykToken = async () => {
@@ -120,7 +126,9 @@ export module stackanalysismodule {
// set up configuration options for the token validation request
let options = {
'EXHORT_SNYK_TOKEN': apiConfig.exhortSnykToken,
- 'EXHORT_DEV_MODE': GlobalState.ExhortDevMode,
+ 'EXHORT_DEV_MODE': process.env.EXHORT_DEV_MODE,
+ 'RHDA_TOKEN': process.env.TELEMETRY_ID,
+ 'RHDA_SOURCE': process.env.UTM_SOURCE
};
// execute stack analysis
diff --git a/test/authextension.test.ts b/test/authextension.test.ts
index 4bcec67d2..0e670ac83 100644
--- a/test/authextension.test.ts
+++ b/test/authextension.test.ts
@@ -19,7 +19,7 @@ suite('authextension Modules', () => {
sandbox.restore();
});
- test('setContextData should set environment variables based on apiConfig', async () => {
+ test('setContextData should set environment variables', async () => {
const mockApiConfig = {
exhortSnykToken: 'mockToken'
};
@@ -31,6 +31,7 @@ suite('authextension Modules', () => {
expect(process.env['SNYK_TOKEN']).equals('mockToken');
expect(process.env['MVN_EXECUTABLE']).equals('mvn');
expect(process.env['NPM_EXECUTABLE']).equals('npm');
+ expect(process.env['GO_EXECUTABLE']).equals('go');
expect(process.env['EXHORT_DEV_MODE']).equals(GlobalState.ExhortDevMode);
});
});
diff --git a/test/config.test.ts b/test/config.test.ts
index a636c9a4b..62f0792cf 100644
--- a/test/config.test.ts
+++ b/test/config.test.ts
@@ -28,15 +28,21 @@ suite('Config module', () => {
expect(apiConfig).to.equal('mockApiConfig');
});
- test('getMavenExecutable should get Maven executable', () => {
- let mavenPath = Config.getMavenExecutable();
+ test('getMvnExecutable should get mvn executable', () => {
+ let mvnPath = Config.getMvnExecutable();
- expect(mavenPath).equals('mvn');
+ expect(mvnPath).equals('mvn');
});
- test('getNodeExecutable should get Node executable', () => {
- let nodePath = Config.getNodeExecutable();
+ test('getNpmExecutable should get npm executable', () => {
+ let npmPath = Config.getNpmExecutable();
- expect(nodePath).equals('npm');
+ expect(npmPath).equals('npm');
+ });
+
+ test('getGoExecutable should get go executable', () => {
+ let goPath = Config.getGoExecutable();
+
+ expect(goPath).equals('go');
});
});
diff --git a/test/multiManifestModule.test.ts b/test/multiManifestModule.test.ts
index 8317700ea..371b57bf7 100644
--- a/test/multiManifestModule.test.ts
+++ b/test/multiManifestModule.test.ts
@@ -34,25 +34,6 @@ suite('multimanifest module', () => {
expect(processStackAnalysisStub.calledOnceWithExactly(context, { uri }, 'maven', uri)).to.be.true;
});
- test('redhatDependencyAnalyticsReportFlow should call triggerFullStackAnalyse once', async () => {
- let triggerFullStackAnalysisSpy = sandbox.spy(multimanifestmodule, 'triggerFullStackAnalysis');
-
- await multimanifestmodule.redhatDependencyAnalyticsReportFlow(context, null);
-
- expect(triggerFullStackAnalysisSpy).to.be.calledOnce;
- });
-
- test('triggerFullStackAnalysis should trigger full stack analysis for specified workspace folder', async () => {
- const workspaceFolder = { uri: vscode.Uri.file('/path/to/mock/workspace') } as vscode.WorkspaceFolder;
- const findFilesStub = sandbox.stub(vscode.workspace, 'findFiles').resolves([vscode.Uri.file('/path/to/mock/pom.xml')]);
- const processStackAnalysisStub = sandbox.stub(stackanalysismodule, 'processStackAnalysis');
-
- await multimanifestmodule.triggerFullStackAnalysis(context, workspaceFolder);
-
- expect(findFilesStub).to.be.calledOnce;
- expect(processStackAnalysisStub.calledOnceWithExactly(context, workspaceFolder, 'maven')).to.be.true;
- });
-
test('triggerManifestWs should resolve with true when authorized and create DependencyReportPanel', async () => {
let authorize_f8_analyticsStub = sandbox.stub(authextension, 'authorize_f8_analytics').resolves(true);
const createOrShowStub = sandbox.stub(DependencyReportPanel, 'createOrShow');
diff --git a/test/stackAnalysisModule.test.ts b/test/stackAnalysisModule.test.ts
index 464055c65..94eaa6cd9 100644
--- a/test/stackAnalysisModule.test.ts
+++ b/test/stackAnalysisModule.test.ts
@@ -8,7 +8,6 @@ import { stackanalysismodule } from '../src/stackanalysismodule';
import { multimanifestmodule } from '../src/multimanifestmodule';
import { stackAnalysisServices } from '../src/stackAnalysisService';
import { Config } from '../src/config';
-import { GlobalState } from '../src/constants';
const expect = chai.expect;
chai.use(sinonChai);
@@ -50,6 +49,19 @@ suite('stackanalysis module', () => {
expect(stackAnalysisLifeCycleStub.calledOnceWithExactly(context, '/path/to/mockFolder/package.json')).to.be.true;
});
+ test('processStackAnalysis should call stackAnalysisLifeCycle for golang', async () => {
+ const workspaceFolder = { uri: vscode.Uri.file('/path/to/mockFolder') } as vscode.WorkspaceFolder;
+ let stackAnalysisLifeCycleStub = sandbox.stub(stackanalysismodule, 'stackAnalysisLifeCycle');
+
+ await stackanalysismodule.processStackAnalysis(
+ context,
+ workspaceFolder,
+ 'golang'
+ );
+
+ expect(stackAnalysisLifeCycleStub.calledOnceWithExactly(context, '/path/to/mockFolder/go.mod')).to.be.true;
+ });
+
test('stackAnalysisLifeCycle should call chain of promises', async () => {
const withProgressSpy = sandbox.spy(vscode.window, 'withProgress');
const triggerManifestWsStub = sandbox.stub(multimanifestmodule, 'triggerManifestWs');
@@ -71,7 +83,7 @@ suite('stackanalysis module', () => {
await stackanalysismodule.validateSnykToken();
expect(getApiConfigStub).to.be.calledOnce;
- expect(getSnykTokenValidationServiceStub.calledOnceWithExactly({ EXHORT_SNYK_TOKEN: 'mockToken', 'EXHORT_DEV_MODE': GlobalState.ExhortDevMode })).to.be.true;
+ expect(getSnykTokenValidationServiceStub.calledOnceWithExactly({ EXHORT_SNYK_TOKEN: 'mockToken', 'EXHORT_DEV_MODE': process.env.EXHORT_DEV_MODE, 'RHDA_TOKEN': process.env.TELEMETRY_ID, 'RHDA_SOURCE': process.env.UTM_SOURCE })).to.be.true;
});
test('validateSnykToken should show information message if no token is provided', async () => {