почему эта ошибка появляется после того, как я запустил реакционную систему? - PullRequest
0 голосов
/ 01 января 2019

Я получил эту ошибку

"Failed to load bundle(http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false) with error:(Unable to resolve module. / Cjs / react.production.min.js from / Тома / Macintosh 1 ТБ / Пользователи / nina / fyp / node_modules / реагировать / index.js : The module. / Cjs / react.production.min.js could not be found from / Объемы / Macintosh 1 ТБ / Пользователи / nina / fyp / node_modules / реагировать / index.js . Indeed, none of these files exist: * / Объемы / Macintosh 1 ТБ / Пользователи / nina / fyp /node_modules / реагируют / CJS / react.production.min.js (.native || .ios.js | .native.js | .js | .ios.json | .native.json | .json | .ios.ts |.native.ts | .ts | .ios.tsx | .native.tsx | .tsx) * / Тома / Macintosh 1 ТБ / Пользователи / nina / fyp / node_modules / реагировать / cjs / Reaction.production.min.js / index(.native || .ios.js | .native.js | .js | .ios.json | .native.json | .json | .ios.ts | .native.ts | .ts | .ios.tsx |.native.tsx | .tsx) (null)) __38-[RCTCxxBridge loadSource:onProgress:]_block_invoke.248 RCTCxxBridge.mm:429 ___ZL36attemptAsynchronousLoadOfBundleAtURLP5NSURLU13block_pointerFvP18RCTLoadingProgressEU13block_pointerFvP7NSErrorP9RCTSourceE_block_invoke.118 __80-[RCTMultipartDataTask URLSession:streamTask:didBecomeInputStream:outputStream:]_block_invoke -[RCTMultipartStreamReader emitChunk:headers:callback:done:] -[RCTMultipartStreamReader readAllPartsWithCompletionCallback:progressCallback:] -[RCTMultipartDataTask URLSession:streamTask:didBecomeInputStream:outputStream:] __88-[NSURLSession delegate_streamTask:didBecomeInputStream:outputStream:completionHandler:]_block_invoke __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ -[NSBlockOperation main] -[__NSOperationInternal _start:] __NSOQSchedule_f _dispatch_call_block_and_release _dispatch_client_callout _dispatch_continuation_pop _dispatch_async_redirect_invoke _dispatch_root_queue_drain _dispatch_worker_thread2 _pthread_wqthread start_wqthread"

После создания нового проекта (init-native init) я запускаю симулятор с помощью response-native run-ios, но он отображает ошибку.

this happens after i ran reset cache: "
events.js:173
      throw er; // Unhandled 'error' event
      ^

Error: listen EADDRINUSE: address already in use :::8081
    at Server.setupListenHandle [as _listen2] (net.js:1255:14)
    at listenInCluster (net.js:1303:12)
    at Server.listen (net.js:1391:7)
    at /Volumes/Macintosh 1TB/Users/nina/fyp/node_modules/metro/src/enter code hereindex.js:193:18
    at new Promise (<anonymous>)
    at Object.<anonymous> (/Volumes/Macintosh 1TB/Users/nina/fyp/node_modules/metro/src/index.js:192:12)
    at Generator.next (<anonymous>)
    at step (/Volumes/Macintosh 1TB/Users/nina/fyp/node_modules/metro/src/index.js:50:30)
    at /Volumes/Macintosh 1TB/Users/nina/fyp/node_modules/metro/src/index.js:61:15
Emitted 'error' event at:
    at Server.WebSocketServer._onServerError (/Volumes/Macintosh 1TB/Users/nina/fyp/node_modules/ws/lib/WebSocketServer.js:82:50)
    at Server.emit (events.js:193:15)
    at emitErrorNT (net.js:1282:8)
    at process.internalTickCallback (internal/process/next_tick.js:72:19)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! fyp@0.0.1 start: `node node_modules/react-native/local-cli/cli.js start`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the fyp@0.0.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Volumes/Macintosh 1TB/Users/aimi/.npm/_logs/2019-01-01T19_50_37_363Z-debug.log"

что я пробовал: удалить node-modules и package-lock.json, а также установить npm, понизив реактивную версию native до версии 0.55.4, очистить кеш с помощью «act-native start --reset-cache ».

что мне делать, чтобы успешно запустить симулятор без ошибки?

...