Actualy I try to intgrat
but I face to this exception my node version is 16.3.2 32bit
C:\Users\PC\Desktop\electron_project_X32\node_modules\express\lib\application.js:630 Error: Loading non-context-aware native module in renderer: '\\?\C:\Users\PC\Desktop\electron_project_X32\node_modules\#chilkat\ck-electron16-win-ia32\chilkat.node'. See https://github.com/electron/electron/issues/18397.
at process.func [as dlopen] (node:electron/js2c/asar_bundle:5)
and this is may package.json
"devDependencies": {
"cpx": "^1.5.0",
"electron": "^16.1.0",
"electron-packager": "^15.4.0",
"electron-rebuild": "^3.2.7",
"ncp": "^2.0.0"
},
"dependencies": {
"#chilkat/ck-electron16-win-ia32": "^9.50.89",
"#chilkat/ck-node16-win-ia32": "^9.50.89",
"cors": "^2.8.5",
"crypto-js": "^4.1.1",
"crypto-md5": "^1.0.0",
"dotenv": "^16.0.0",
"electron-tabs": "^0.15.0",
"express": "^4.17.3",
"ffi-napi": "^4.0.3",
"freemarker": "^2.0.1",
"md5": "^2.3.0",
"multer": "^1.4.4",
"node-cron": "^3.0.0",
"node-key-sender": "^1.0.11",
"node-notifier": "^10.0.1",
"npm": "^8.5.3",
"pkg": "^5.5.2",
"serialport": "^10.4.0",
"sudo-prompt": "^9.2.1",
"through2": "^4.0.2",
"websocket": "^1.0.34"
}
I try to set this app.allowRendererProcessReuse = false in main.js but it don't solve the problem
SOLVED BY #chilkat Software by upgrading the current version of chilkat/ck-electron16-win64 and win32
Related
I'm using visual studio code with node v18.
I use structuredClone in my application and it runs fine but when it comes to running a test I get
"ReferenceError: structuredClone is not defined"
I don't know how mocha works, but is it for some reason using an older version of node or is there some other dependency creating an issue?
"dependencies": {
"#sendgrid/mail": "^7.6.2",
"#types/chai": "^4.3.1",
"#types/express": "^4.17.13",
"#types/mocha": "^9.1.1",
"#types/node": "^18.0.0",
"#types/npm": "^7.19.0",
"bcrypt": "^5.0.1",
"body-parser": "^1.19.2",
"chai": "^4.3.6",
"connect-flash": "^0.1.1",
"cookie-parser": "^1.4.6",
"dotenv": "^16.0.0",
"eventemitter2": "^6.4.5",
"express": "^4.17.3",
"express-validator": "^6.14.0",
"jsdom": "^20.0.0",
"jsonwebtoken": "^8.5.1",
"marked": "^4.0.12",
"memory-cache": "^0.2.0",
"mocha": "^10.0.0",
"mssql": "^8.0.2",
"sanitize-html": "^2.7.0",
"validator": "^13.7.0",
"xsg.spider": "file:./../spider"
},
"devDependencies": {
"#types/bcrypt": "^5.0.0",
"#types/connect-flash": "^0.0.37",
"#types/cookie-parser": "^1.4.2",
"#types/dompurify": "^2.3.3",
"#types/jsdom": "^16.2.14",
"#types/jsonwebtoken": "^8.5.8",
"#types/marked": "^4.0.3",
"#types/memory-cache": "^0.2.2",
"#types/mssql": "^7.1.5",
"#types/passport-local": "^1.0.34",
"#types/sanitize-html": "^2.6.2",
"#types/validator": "^13.7.2",
"nyc": "^15.1.0",
"ts-node": "^10.7.0",
"typescript": "^4.6.4"
}
It's probably a bug, as a turnaround to deep clone your object, you can use JSON.parse & JSON.stringify:
if (global.structuredClone)
clonedObject = structuredClone(object)
else
clonedObject = JSON.parse(JSON.stringify(object))
I have used mongoose package in my nest project but when I am trying to build the project using npm run build.Then its throwing below error in my console:
node_modules/mongoose/node_modules/mongodb/mongodb.d.ts:34:15 - error TS2305: Module '"tls"'
has no exported member 'TLSSocketOptions'.
34 import type { TLSSocketOptions } from 'tls';
I have even updated the mongoose package to the latest version.Then also I am getting the same error:
Below are my dependencies inside package.json file:
"dependencies": {
"#apollo/gateway": "^0.38.0",
"#google-cloud/translate": "^6.2.1",
"#nestjs/common": "^8.0.6",
"#nestjs/core": "^8.0.6",
"#nestjs/cqrs": "^8.0.0",
"#nestjs/graphql": "^8.0.2",
"#nestjs/microservices": "^8.0.6",
"#nestjs/mongoose": "^9.0.3",
"#nestjs/platform-express": "^8.0.6",
"#types/luxon": "^1.15.1",
"apollo-server-express": "^2.25.2",
"bunyan": "^1.8.12",
"bunyan-rotating-file-stream": "^1.6.3",
"connect-redis": "^3.4.1",
"consul": "^0.40.0",
"device-detector-js": "^3.0.3",
"elasticsearch": "^16.2.0",
"express-session": "^1.16.2",
"firebase-admin": "^9.4.2",
"graphql": "^14.7.0",
"graphql-tools": "^4.0.4",
"json-rules-engine": "^3.1.0",
"kafkajs": "^1.15.0",
"lodash": "^4.17.21",
"luxon": "^1.16.0",
"moneysafe": "^2.2.1",
"mongodb": "^3.5.9",
"mongoose": "^6.3.0",
"nestjs-i18n": "^8.1.1",
"node-wit": "^6.0.0",
"reflect-metadata": "^0.1.12",
"rimraf": "^2.6.2",
"rxjs": "^7.3.0",
"ts-morph": "^12.0.0",
"typescript": "^4.3.5",
"uuid": "^3.3.2"
},
"devDependencies": {
"#nestjs/testing": "^5.1.0",
"#types/jest": "^23.3.1",
"#types/lodash": "^4.14.134",
"#types/node": "^10.7.1",
"#types/supertest": "^2.0.5",
"jest": "^23.5.0",
"nodemon": "^1.18.3",
"prettier": "^1.14.2",
"supertest": "^3.1.0",
"ts-jest": "^23.1.3",
"ts-loader": "^4.4.2",
"ts-node": "^7.0.1",
"tsconfig-paths": "^3.5.0",
"tslint": "5.11.0"
}
Someone let me know how can I resolve this error.Any help on this will be really appreciated.
I fixed this by updating #types/node to the latest version. This specific error message is then fixed!
Here is the package.json from my project, I've ran npm install.
npm run dev is working fine on localhost. After 1 hour, when I restart my computer, I got the following error
Module build failed (from ./node_modules/less-loader/dist/cjs.js): #import url('https://fonts.googleapis.com/css2?family=Noto+Sans:wght#400;700&family=Roboto:wght#100;300;400;500;700;900&display=swap'); #import url('https://fonts.googleapis.com/css2?family=Prompt:ital,wght#0,200;0,300;1,200&display=swap'); ^ Resource 'https://fonts.googleapis.com/css2?family=Prompt:ital,wght#0,200;0,300;1,200&display=swap' gave this Error: Error: socket hang up Error in C:\xampp\htdocs\frontend\assets\styles\custom.less (line 5, column 0)
I already solved this issue once by deleting my node_modules.
But here, even after removing my package-lock.json, the issue persists.
{
"dependencies": {
"#babel/core": "^7.16.5",
"#babel/preset-env": "^7.16.5",
"#fullcalendar/daygrid": "^5.8.0",
"#fullcalendar/interaction": "^5.8.0",
"#fullcalendar/timegrid": "^5.8.0",
"#fullcalendar/vue": "^5.8.0",
"#line/liff": "^2.8.0",
"#nuxt/content": "1.8.1",
"#nuxtjs/auth": "4.9.1",
"#nuxtjs/axios": "^5.12.2",
"#nuxtjs/dotenv": "^1.4.1",
"#nuxtjs/pwa": "3.0.2",
"ant-design-vue": "1.6.5",
"apexcharts": "^3.27.1",
"axios": "^0.20.0",
"bootstrap": "5.0.0-alpha2",
"downloadjs": "^1.4.7",
"html-to-image": "^1.6.2",
"nuxt": "2.14.4",
"nuxt-cookie-control": "1.9.9",
"nuxt-i18n": "6.13.12",
"object-fit-images": "^3.2.4",
"omise": "^0.8.5",
"quasar": "^1.15.21",
"vue-apexcharts": "^1.6.1",
"vue-fb-customer-chat": "^0.2.0",
"vue-google-oauth2": "^1.5.8",
"vue-meta": "^2.4.0",
"vue-social-sharing": "^3.0.7"
},
"devDependencies": {
"#nuxtjs/eslint-config": "3.1.0",
"#nuxtjs/eslint-module": "2.0.0",
"#nuxtjs/moment": "^1.6.1",
"#vue/test-utils": "1.0.5",
"babel-core": "7.0.0-bridge.0",
"babel-eslint": "10.1.0",
"babel-jest": "26.3.0",
"eslint": "7.8.1",
"eslint-plugin-nuxt": "1.0.0",
"jest": "26.4.2",
"less": "3.12.2",
"less-loader": "7.0.1",
"node-sass": "^4.14.1",
"sass": "^1.32.13",
"stylus": "^0.54.8",
"stylus-loader": "^6.1.0",
"vue-jest": "3.0.6"
}
Enviroment
React Native CLI 0.63.2
Windows 10 x64 bit
Node v14.4.0
Packages (package.json):
"dependencies": {
"#fortawesome/fontawesome-svg-core": "^1.2.30",
"#fortawesome/free-solid-svg-icons": "^5.14.0",
"#fortawesome/react-native-fontawesome": "^0.2.5",
"#react-native-community/async-storage": "^1.12.1",
"#react-native-community/blur": "^3.6.0",
"#react-native-community/datetimepicker": "^3.0.4",
"#react-native-community/masked-view": "^0.1.10",
"#react-native-community/netinfo": "^5.9.7",
"#react-native-community/picker": "^1.8.1",
"#react-native-firebase/app": "^8.4.6",
"#react-navigation/native": "^5.7.1",
"#react-navigation/stack": "^5.7.1",
"md5": "^2.3.0",
"moment": "^2.27.0",
"react": "16.13.1",
"react-hook-form": "^6.4.1",
"react-native": "0.63.2",
"react-native-code-push": "^6.3.0",
"react-native-code-push-saga": "^1.0.1",
"react-native-gesture-handler": "^1.8.0",
"react-native-reanimated": "^1.13.1",
"react-native-safe-area-context": "^3.1.7",
"react-native-safe-area-view": "^1.1.1",
"react-native-screens": "^2.9.0",
"react-native-snap-carousel": "^4.0.0-beta.5",
"react-native-svg": "^12.1.0",
"react-native-ui-lib": "^5.15.0",
"react-redux": "^7.2.1",
"redux": "^4.0.5",
"redux-logger": "^3.0.6",
"redux-saga": "^1.1.3"
},
"devDependencies": {
"#babel/core": "7.10.5",
"#babel/runtime": "7.10.5",
"#react-native-community/eslint-config": "1.1.0",
"babel-jest": "25.5.1",
"eslint": "6.8.0",
"jest": "25.5.4",
"metro-react-native-babel-preset": "0.59.0",
"react-native-svg-transformer": "^0.14.3",
"react-test-renderer": "16.13.1"
}
Problem
Whenever I import #react-native-community/netinfo or #react-native-community/async-storage it seems to work fine on Android Emulator. However if I test it live on my iPhone 11 device it crashes almost instantly. All I have to do in order to reproduce the problem is only to import the packages and run it on a iOS device.
I currently don't have the ability to debug for iOS devices as I do not own a MacOS. Is this a known bug or is there a solution to this?
Both packages are from React Native community maybe there is a pattern there. Maybe the packages are affecting other packages causing a crash.
Error Log On initiating application
While initiating the application it shows the following error and i tried couple of fixes from online which has mentioned below but none of them has worked requesting for suggestions and solutions
node_modules/#types/graphql/subscription/subscribe.d.ts(17,12): error TS2304: Cannot find name 'AsyncIterator'.
node_modules/#types/graphql/subscription/subscribe.d.ts(29,12): error TS2304: Cannot find name 'AsyncIterable'.
node_modules/graphql-tools/dist/stitching/makeRemoteExecutableSchema.d.ts(3,109): error TS2304: Cannot find name 'AsyncIterator'.
Fixes Tried as per google results
Adding esnext.asynciterable to the tsconfig.json
Adding esnext to the tsconfig.json
But none of them has worked.
package.json
"dependencies": {
"async": "^2.6.0",
"body-parser": "^1.18.2",
"cookie-parser": "^1.4.3",
"cors": "^2.8.4",
"ejs": "^2.5.7",
"errorhandler": "^1.5.0",
"express": "^4.16.2",
"express-graphql": "^0.6.12",
"graphql": "^0.13.2",
"graphql-tools": "^3.1.1",
"ldapjs": "^1.0.1",
"method-override": "^2.3.10",
"moment": "^2.20.1",
"mongoose": "^4.13.6",
"morgan": "^1.9.0",
"mysql": "^2.15.0",
"node-schedule": "^1.3.0",
"nodemiral": "^1.1.1",
"pug": "^2.0.0-rc.4",
"q": "^1.5.1",
"request": "^2.85.0",
"sendmail": "^1.2.0",
"serve-favicon": "^2.4.5",
"socket.io": "^2.0.4",
"ts-node": "^3.3.0"
},
"devDependencies": {
"#types/async": "^2.0.47",
"#types/body-parser": "^1.16.8",
"#types/chai": "^4.0.8",
"#types/chai-http": "^3.0.3",
"#types/cookie-parser": "^1.4.1",
"#types/cors": "^2.8.3",
"#types/errorhandler": "0.0.32",
"#types/ldapjs": "^1.0.3",
"#types/lodash": "^4.14.106",
"#types/method-override": "0.0.31",
"#types/mocha": "^2.2.44",
"#types/mongodb": "^2.2.16",
"#types/mongoose": "^4.7.28",
"#types/morgan": "^1.7.35",
"#types/mysql": "^2.15.3",
"#types/node-schedule": "^1.2.2",
"#types/request": "^2.47.0",
"#types/serve-favicon": "^2.2.30",
"#types/socket.io": "^1.4.32",
"chai": "^4.1.2",
"chai-http": "^3.0.0",
"grunt": "^1.0.1",
"grunt-concurrent": "^2.3.1",
"grunt-contrib-copy": "^1.0.0",
"grunt-contrib-watch": "^1.0.0",
"grunt-mocha-test": "^0.13.3",
"grunt-newer": "^1.3.0",
"grunt-nodemon": "^0.4.2",
"grunt-ts": "^6.0.0-beta.17",
"grunt-tslint": "^5.0.1",
"grunt-typedoc": "^0.2.4",
"mocha": "^4.0.1",
"mocha-typescript": "^1.1.12",
"nodemon": "^1.12.4",
"tslint": "^5.8.0",
"typescript": "^2.6.2"
}
Delete node modules then:-
npm install
npm install --save graphql-subscriptions
npm install --save #types/graphql
npm install --save #types/ws
add the following in tsconfig.json
"compilerOptions": {
"lib": [
"esnext.asynciterable"
]
I encountered the same problem and adding
"lib": ["es2017", "esnext", "esnext.asynciterable"]
to my tsconfig.json did not help, which was frustrating.
I went through lots of suggestions and eventually the answer by Shivendra solved it for me. Hope this will help others coming here in the future.