I get a clang error when running rush lint fix - xcode

I'm trying to run rush lint fix (to run the linting on the code), and I get the following error:
node:internal/child_process:413
throw errnoException(err, 'spawn');
^
Error: spawn Unknown system error -86
at ChildProcess.spawn (node:internal/child_process:413:11)
at spawn (node:child_process:700:9)
at /Users/wscott/dev/hz/common/temp/node_modules/.pnpm/clang-format#1.5.0/node_modules/clang-format/index.js:91:42
at /Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:3641:28
at replenish (/Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:446:21)
at /Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:451:13
at eachOfLimit$1 (/Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:477:34)
at awaitable (/Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:211:32)
at eachOfSeries (/Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:813:16)
at awaitable (/Users/wscott/dev/hz/common/temp/node_modules/.pnpm/async#3.2.2/node_modules/async/dist/async.js:211:32) {
errno: -86,
code: 'Unknown system error -86',
syscall: 'spawn'
}
Does anyone know what the problem is?

Related

Getting this error after running in the cypress dashboard

I am getting this are after running all of my test cases in the cypress dashboard. Can anyone help me to solve this issue? Test cases are running no issues in there.
An error was thrown in your plugins file while executing the handler for the after:run event.
The error we received was:
Error: spawn cucumber-json-formatter.exe ENOENT
at Process.ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at processTicksAndRejections (node:internal/process/task_queues:83:21)

sass with auto-refresh using parcel , getting errno: -4058, code: 'ENOENT' when running start script

I'm trying to setup Sass with auto-refresh using parcel,
and when I'm using script "start": "parcel src/index.html", I'm constantly getting the following error:
Error: ENOENT: no such file or directory, open 'D:\vscodeprojects\RSSchool\dict\dict.txt'
at Object.openSync (node:fs:585:3)
at Object.readFileSync (node:fs:453:35)
at makeCompression (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules\lmdb\dist\index.cjs:2047:19)
at Object.open (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules\lmdb\dist\index.cjs:2057:25)
at new LMDBCache (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules#parcel\cache\lib\LMDBCache.js:81:34)
at resolveOptions (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules#parcel\core\lib\resolveOptions.js:125:168)
at async Parcel._init (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules#parcel\core\lib\Parcel.js:218:27)
at async Parcel.watch (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules#parcel\core\lib\Parcel.js:315:7)
at async run (D:\vscodeprojects\RSSchool\Stage#1\imdenver-JSFELT\english_for_kids\node_modules\parcel\lib\cli.js:351:9) {
errno: -4058,
syscall: 'open',
code: 'ENOENT',
path: 'D:\vscodeprojects\RSSchool\dict\dict.txt'
}
This dict file outside of the project folder doesn't make sense.
Please advise.
I cloned into your repo and run with below package.json config
Replaced "start":"parcel src/index.html" with "start":"parcel"
App runs

yarn deploy give error with Command failed with exit code 1 when running collection-examples-as

I am trying to run the collection-examples-as near example but when I run yarn deploy it gives me the following error
$ near dev-deploy --wasmFile="./contract.wasm"
Starting deployment. Account id: dev-1637744501224-6323200, node:
https://rpc.testnet.near.org, helper: https://helper.testnet.near.org, file:
./contract.wasm
An error occurred
Error: ENOENT: no such file or directory, open './contract.wasm'
[Error: ENOENT: no such file or directory, open './contract.wasm'] {
errno: -2,
code: 'ENOENT',
syscall: 'open',
path: './contract.wasm'
}
error Command failed with exit code 1.
I think the error is it can't find the path to ./contract.wasm so I run yarn build the I tried to deploy it again using yarn deploy but I got another error which is:
$ near dev-deploy --wasmFile="./contract.wasm"
Starting deployment. Account id: dev-1637744501224-6323200, node:
https://rpc.testnet.near.org, helper: https://helper.testnet.near.org, file:
./contract.wasm
An error occurred
Error: Can not sign transactions for account dev-1637744501224-6323200 on network
default, no matching key pair found in
InMemorySigner(MergeKeyStore(UnencryptedFileSystemKeyStore(/home/rasha/.near-
credentials), UnencryptedFileSystemKeyStore(/home/rasha/collection-examples-
as/neardev))).
{
type: 'KeyNotFound',
context: undefined
}
any help or suggestions?
There's an issue with old versions of near-cli and dev-deploy.
As a workaround, you can try running the latest cli directly from your terminal:
near dev-deploy --wasmFile="./contract.wasm" -f
Just check that you installed the latest version of near-cli, currently 2.2.0. You can check your version with near --version.
Be sure to run yarn build first, so you'll have the compiled contract.wasm file.
Note: When you run yarn deploy, it uses the old near-cli version defined in package.json. (probably some old version like 1.6.0)
You might also want to check this GitHub issue (dev-deploy error): https://github.com/near/create-near-app/issues/1408

yarn permission problems on OSX high sierra

I'm really scratching my head on this one, and have spent around 1.5 days on trying to resolve the problem
the problem I think has to do with permissions that somehow got reset -
I suspect it happened after I got boot camp assistant to partition for windows dual boot
Environment:
Writing selenium test cases in typescript, using Alsatian and Zalenium frameworks over ts-node - the following command being used to initialise the test runner
yarn run ts-node Tests/runner.ts --tap
yarn environment is running through brew
package.json:
{
"dependencies": {
"#types/dotenv": "^4.0.2",
"#types/selenium-webdriver": "^3.0.8",
"alsatian": "^2.2.1",
"axios": "^0.17.1",
"dotenv": "^5.0.0",
"moment": "^2.20.1",
"selenium-webdriver": "^4.0.0-alpha.1",
"tap-spec": "^4.1.1",
"ts-node": "^4.1.0",
"tslib": "1.8.1",
"typescript": "^2.6.2"
}
}
runner.ts:
import tapSpec = require('tap-spec');
import { TestSet, TestRunner } from "alsatian";
import { config as dotenv } from 'dotenv';
(async () =>
{
// Load up any pseudo environment variables
dotenv({ path: __dirname + '/../.env' });
// Setup the alsatian test runner
let testRunner = new TestRunner();
let tapStream = testRunner.outputStream;
let testSet = TestSet.create();
testSet.addTestsFromFiles('/**/*/*.spec.ts');
// This will output a human readable report to the console.
tapStream.pipe(tapSpec()).pipe(process.stdout);
// Runs the tests
await testRunner.run(testSet);
})()
.catch(e =>
{
console.error(e);
process.exit(1);
});
Problem:
I suspect the problems started after I installed dual boot windows using bootcamp assistant
I worked in windows for 3-4 days on another project and when I came back, started getting permission problems
initially they were along the lines of { Error: EACCES: permission denied, scandir '/Library/Application Support/xxxx'
which I resolved using chmod as stated below - now I'm stuck - read points 7 and 8, I don't know whats causing the problem - but I suspect it's yarn permissions
I had - also updated to typescript 2.7.1 earlier because I'm using the option "strictPropertyInitialization": false, in tsconfig - initially I thought that had cause some problem, but reverting to 2.6.2 hasn't resolved it
removed and rebuilt node_modules
ran first aid from disk utility on partition
reset permissions : https://support.apple.com/en-us/HT203538
re-installed yarn
re-installed brew
granted each complained folder sudo chmod -R 777 '/Library/Application Support', now complaining about no access to '/System/Library/User Template' , cannot use chmod here because I get the error, operation not allowed
yarn run ts-node Tests/runner.ts --tap gives:
warning package.json: No license field
$ /Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/.bin/ts-node Tests/runner.ts --tap
{ Error: EACCES: permission denied, scandir '/System/Library/User Template'
at Object.fs.readdirSync (fs.js:924:18)
at GlobSync._readdir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:288:41)
at GlobSync._readdirInGlobStar (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:267:20)
at GlobSync._readdir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:276:17)
at GlobSync._processReaddir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:137:22)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:132:10)0
at GlobSync._processReaddir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:207:10)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:132:10)
at GlobSync._processGlobStar (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:380:10)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:130:10)
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/System/Library/User Template' }
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
sudo yarn run ts-node Tests/runner.ts --tap gives:
{ Error: EBADF: bad file descriptor, scandir '/dev/fd/13'
at Object.fs.readdirSync (fs.js:924:18)
at GlobSync._readdir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:288:41)
at GlobSync._readdirInGlobStar (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:267:20)
at GlobSync._readdir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:276:17)
at GlobSync._processReaddir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:137:22)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:132:10)
at GlobSync._processReaddir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:207:10)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:132:10)
at GlobSync._processGlobStar (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:380:10)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:130:10)
errno: -9,
code: 'EBADF',
syscall: 'scandir',
path: '/dev/fd/13' }
error Command failed with exit code 1.
UPDATE 1 - 19 FEB 2017:
I've placed a test.ts file - which does nothing but print to console , if I call that from yarn ts-node, that works fine
yarn run ts-node Tests/test.ts
output:
yarn run v1.3.2
warning package.json: No license field
$ /Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/.bin/ts-node Tests/test.ts
this is a test
✨ Done in 0.61s.
test.ts:
(async () =>
{
console.log("this is a test");
})()
.catch(e =>
{
console.error(e);
process.exit(1);
});
I have also attempted, what the comment has suggested by #ILI - I fixed the permissions using First Aid in disk utility on the mac partition , since brew no longer supports sudo, I uninstalled yarn from brew, and added it to global packages using
sudo yarn install yarn -g
but still have the same EACCESS error - Error: EACCES: permission denied, scandir '/Library/Application Support/OpenVPN/profile'
Also tried running yarn --verbose, didn't get much detail from there
yarn run --verbose ts-node Tests/runner.ts --tap
yarn run v1.3.2
warning package.json: No license field
verbose 0.331 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/.npmrc".
verbose 0.331 Checking for configuration file "/Users/dshamim/.npmrc".
verbose 0.331 Checking for configuration file "/usr/local/etc/npmrc".
verbose 0.332 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/.npmrc".
verbose 0.332 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/anex/.npmrc".
verbose 0.332 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/.npmrc".
verbose 0.332 Checking for configuration file "/Users/dshamim/Projects/Acurus/.npmrc".
verbose 0.332 Checking for configuration file "/Users/dshamim/Projects/.npmrc".
verbose 0.332 Checking for configuration file "/Users/dshamim/.npmrc".
verbose 0.333 Checking for configuration file "/Users/.npmrc".
verbose 0.333 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/.yarnrc".
verbose 0.333 Checking for configuration file "/Users/dshamim/.yarnrc".
verbose 0.334 Found configuration file "/Users/dshamim/.yarnrc".
verbose 0.334 Checking for configuration file "/usr/local/etc/yarnrc".
verbose 0.334 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/.yarnrc".
verbose 0.334 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/anex/.yarnrc".
verbose 0.334 Checking for configuration file "/Users/dshamim/Projects/Acurus/ANEX/.yarnrc".
verbose 0.335 Checking for configuration file "/Users/dshamim/Projects/Acurus/.yarnrc".
verbose 0.337 Checking for configuration file "/Users/dshamim/Projects/.yarnrc".
verbose 0.338 Checking for configuration file "/Users/dshamim/.yarnrc".
verbose 0.338 Found configuration file "/Users/dshamim/.yarnrc".
verbose 0.338 Checking for configuration file "/Users/.yarnrc".
verbose 0.34 current time: 2018-02-19T00:39:49.960Z
$ /Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/.bin/ts-node Tests/runner.ts --tap
{ Error: EACCES: permission denied, scandir '/Library/Application Support/OpenVPN/profile'
at Object.fs.readdirSync (fs.js:924:18)
at GlobSync._readdir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:288:41)
at GlobSync._readdirInGlobStar (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:267:20)
at GlobSync._readdir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:276:17)
at GlobSync._processReaddir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:137:22)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:132:10)
at GlobSync._processReaddir (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:207:10)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:132:10)
at GlobSync._processGlobStar (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:380:10)
at GlobSync._process (/Users/dshamim/Projects/Acurus/ANEX/anex/ANEX.Website.ManagementPortal.Tests/node_modules/glob/sync.js:130:10)
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/Library/Application Support/OpenVPN/profile' }
verbose 51.049 Error: Command failed with exit code 1.
at /usr/local/Cellar/yarn/1.3.2/libexec/lib/cli.js:35620:15
at Generator.throw (<anonymous>)
at step (/usr/local/Cellar/yarn/1.3.2/libexec/lib/cli.js:92:30)
at /usr/local/Cellar/yarn/1.3.2/libexec/lib/cli.js:105:13
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:160:7)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Some times it's the simple things that we miss, don't worry we have all been here.
This is a case of over thinking the issue, to steal a line from an Aussie beer commercial, you need to "UNDERTHINK IT". https://youtu.be/1MdAhVetBq8
The fact that your simple test script worked but the main test runner didn't, would have pointed me in the direction of stepping through the test runner script, rather than looking at yarn or any other culprit.
Turns out you were telling alsatian to search your entire hard drive for test cases, in which some folders it did not have permissions to access.
Change:
testSet.addTestsFromFiles('/**/*/*.spec.ts');
To:
testSet.addTestsFromFiles('**/*/*.spec.ts');
Or:
testSet.addTestsFromFiles('./**/*/*.spec.ts');
And all should work as you expect.

forever cannot find .js files on windows 2008 x64

var forever = require('forever-monitor');
var panel = new (forever.Monitor)('p.js');
panel.start();
this code outputs :
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:980:11)
at Process.ChildProcess._handle.onexit (child_process.js:771:34)
at first i thought my code has a problem so i installed forever globally and tried
forever p.js
and it says
C:\w>forever p.js
warn: --minUptime not set. Defaulting to: 1000ms
warn: --spinSleepTime not set. Your script will exit if it does not stay up for at least 1000ms
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:980:11)
at Process.ChildProcess._handle.onexit (child_process.js:771:34)
while node p.js in the same directory works just fine , the file is there
when trying to run a non-existent file forever gives a different error message
any clues on where to look is appreciated .
try with C:\w>forever -c node p.js
was the fix to my problem...

Resources