GithubHelp home page GithubHelp logo

Comments (15)

anp avatar anp commented on May 22, 2024 2

@rtpm cool -- makes sense. I'm going to prioritize making ((Windows + yarn) - MSVC) work well right now, and I can revisit docker support soon.

from create-react-native-app.

anp avatar anp commented on May 22, 2024

Hi! Thanks for the report! Sorry this isn't working for you. Can you paste the contents of package.json in the directory where this failed?

I'm seeing some warnings about an organizational NPM mirror being configured in an environment variable, and I'm wondering if perhaps the mirror you have set hasn't pulled the latest version of the dependencies? A previous version of one of the dependencies wasn't able to build without a compiler toolchain (kind of defeating the purpose of this 😅 ).

from create-react-native-app.

viniciusCamargo avatar viniciusCamargo commented on May 22, 2024

No problem! I'm just looking forward to try it asap. It's really exciting stuff. 😄

The package.json don't say much:

{
  "name": "my-app",
  "version": "0.1.0",
  "private": true
}

I'm not sure about the mirror I've set though. Should I try something different besides the usual $ create-react-native-app my-app?

from create-react-native-app.

dentemple avatar dentemple commented on May 22, 2024

It seems I have a similar error, and on a different system.

Node v7.5.0
Windows 10 / Surface Pro (using Git Bash)

Package.json:

{
  "name": "native-app-example",
  "version": "0.1.0",
  "private": true
}

Error:

(yarn add v0.18.1
info No lockfile found.
[1/4] Resolving packages...
warning react-native-scripts > xdl > [email protected]: use uuid module instead
warning react-native-scripts > xdl > @exponent/ngrok > [email protected]: use uuid module instead
warning react-native-scripts > xdl > auth0-js > xtend > [email protected]:
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/5] ⠈ @exponent/ngrok: ngrok - downloading binary https://bin.equinox.io/c/6raCnPaTf2c/ngrok-beta-windows-am
[-/5] ⠁ waiting...
[3/5] ⠁ ref: spawn args   '-Goutput_dir=.' ]
[4/5] ⠁ runas: gyp info spawn args   '-Goutput_dir=.' ]
error Error running install script for optional dependency: "C:\\Sites\\native-app-example\\node_modules\\runas: Command failed.\nExit code: 1\nCommand: C:\\WINDOWS\\system32\\cmd.exe\nArguments: /d /s /c node-gyp rebuild\nDirectory: C:\\Sites\\native-app-example\\node_modules\\runas\nOutput:\nC:\\Sites\\native-app-example\\node_modules\\runas>if not defined npm_config_node_gyp (node \"c:\\Program Files (x86)\\Yarn\\bin\\node-gyp-bin\\\\..\\..\\node_modules\\node-gyp\\bin\\node-gyp.js\" rebuild )  else (node  rebuild ) \r\ngyp info it worked if it ends with ok\ngyp info using [email protected]\ngyp info using [email protected] | win32 | x64\ngyp info spawn c:\\Python27\\python.EXE\ngyp info spawn args [ 'c:\\\\Program Files (x86)\\\\Yarn\\\\node_modules\\\\node-gyp\\\\gyp\\\\gyp_main.py',\ngyp info spawn args   'binding.gyp',\ngyp info spawn args   '-f',\ngyp info spawn args   'msvs',\ngyp info spawn args   '-G',\ngyp info spawn args   'msvs_version=auto',\ngyp info spawn args   '-I',\ngyp info spawn args   'C:\\\\Sites\\\\native-app-example\\\\node_modules\\\\runas\\\\build\\\\config.gypi',\ngyp info spawn args   '-I',\ngyp info spawn args   'c:\\\\Program Files (x86)\\\\Yarn\\\\node_modules\\\\node-gyp\\\\addon.gypi',\ngyp info spawn args   '-I',\ngyp info spawn args   'c:\\\\Users\\\\denny\\\\.node-gyp\\\\7.5.0\\\\include\\\\node\\\\common.gypi',\ngyp info spawn args   '-Dlibrary=shared_library',\ngyp info spawn args   '-Dvisibility=default',\ngyp info spawn args   '-Dnode_root_dir=c:\\\\Users\\\\denny\\\\.node-gyp\\\\7.5.0',\ngyp info spawn args   '-Dnode_gyp_dir=c:\\\\Program Files (x86)\\\\Yarn\\\\node_modules\\\\node-gyp',\ngyp info spawn args   '-Dnode_lib_file=node.lib',\ngyp info spawn args   '-Dmodule_root_dir=C:\\\\Sites\\\\native-app-example\\\\node_modules\\\\runas',\ngyp info spawn args   '--depth=.',\ngyp info spawn args   '--no-parallel',\ngyp info spawn args   '--generator-output',\ngyp info spawn args   'C:\\\\Sites\\\\native-app-example\\\\node_modules\\\\runas\\\\build',\ngyp info spawn args   '-Goutput_dir=.' ]\nTraceback (most recent call last):\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\gyp_main.py\", line 16, in <module>\r\n    sys.exit(gyp.script_main())\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\__init__.py\", line 545, in script_main\r\n    return main(sys.argv[1:])\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\__init__.py\", line 538, in main\r\n    return gyp_main(args)\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\__init__.py\", line 514, in gyp_main\r\n    options.duplicate_basename_check)\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\__init__.py\", line 130, in Load\r\n    params['parallel'], params['root_targets'])\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\input.py\", line 2775, in Load\r\n    variables, includes, depth, check, True)\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\input.py\", line 417, in LoadTargetBuildFile\r\n    build_file_data, PHASE_EARLY, variables, build_file_path)\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\input.py\", line 1214, in ProcessVariablesAndConditionsInDict\r\n    variables, build_file, 'variables')\r\n  File \"c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\pylib\\gyp\\input.py\", line 1225, in ProcessVariablesAndConditionsInDict\r\n    'only, found ' + expanded.__class__.__name__ + ' for ' + key)\r\nValueError: Variable expansion in this context permits str and int only, found long for lastUpdateCheck while trying to load binding.gyp\r\ngyp ERR! configure error \ngyp ERR! stack Error: `gyp` failed with exit code: 1\ngyp ERR! stack     at ChildProcess.onCpExit (c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\lib\\configure.js:305:16)\ngyp ERR! stack     at emitTwo (events.js:106:13)\ngyp ERR! stack     at ChildProcess.emit (events.js:192:7)\ngyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)\ngyp ERR! System Windows_NT 10.0.14393\ngyp ERR! command \"c:\\\\Program Files\\\\nodejs\\\\node.ex[1/5] ⠁ @exponent/ngrok: ngrok - downloading binary https://bin.equinox.io/c/6raCnPaTf2c/ngrok-beta-windows-am
:\\Sites\\native-app-example\\node_modules\\runas\ngyp ERR! node -v v7.5.0\ngyp ERR! node-gyp -v v3.4.0\ngyp ERR! not ok"
info This module is OPTIONAL, you can safely ignore this error
error C:\Sites\native-app-example\node_modules\ref: Command failed.
Exit code: 1
Command: C:\WINDOWS\system32\cmd.exe
Arguments: /d /s /c node-gyp rebuild
Directory: C:\Sites\native-app-example\node_modules\ref
Output:
C:\Sites\native-app-example\node_modules\ref>if not defined npm_config_node_gyp (node "c:\Program Files (x86)\Yarn\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node  rebuild )
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp info spawn c:\Python27\python.EXE
gyp info spawn args [ 'c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\gyp\\gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'msvs',
gyp info spawn args   '-G',
gyp info spawn args   'msvs_version=auto',
gyp info spawn args   '-I',
gyp info spawn args   'C:\\Sites\\native-app-example\\node_modules\\ref\\build\\config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   'c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   'c:\\Users\\denny\\.node-gyp\\7.5.0\\include\\node\\common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=c:\\Users\\denny\\.node-gyp\\7.5.0',
gyp info spawn args   '-Dnode_gyp_dir=c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp',
gyp info spawn args   '-Dnode_lib_file=node.lib',
gyp info spawn args   '-Dmodule_root_dir=C:\\Sites\\native-app-example\\node_modules\\ref',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'C:\\Sites\\native-app-example\\node_modules\\ref\\build',
gyp info spawn args   '-Goutput_dir=.' ]
Traceback (most recent call last):
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\gyp_main.py", line 16, in <module>
    sys.exit(gyp.script_main())
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 545, in script_main
    return main(sys.argv[1:])
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 538, in main
    return gyp_main(args)
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 514, in gyp_main
    options.duplicate_basename_check)
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\__init__.py", line 130, in Load
    params['parallel'], params['root_targets'])
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\input.py", line 2775, in Load
    variables, includes, depth, check, True)
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\input.py", line 417, in LoadTargetBuildFile
    build_file_data, PHASE_EARLY, variables, build_file_path)
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\input.py", line 1214, in ProcessVariablesAndConditionsInDict
    variables, build_file, 'variables')
  File "c:\Program Files (x86)\Yarn\node_modules\node-gyp\gyp\pylib\gyp\input.py", line 1225, in ProcessVariablesAndConditionsInDict
    'only, found ' + expanded.__class__.__name__ + ' for ' + key)
ValueError: Variable expansion in this context permits str and int only, found long for lastUpdateCheck while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (c:\Program Files (x86)\Yarn\node_modules\node-gyp\lib\configure.js:305:16)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:192:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "c:\\Program Files\\nodejs\\node.exe" "c:\\Program Files (x86)\\Yarn\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Sites\native-app-example\node_modules\ref
gyp ERR! node -v v7.5.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
`yarnpkg add --dev --exact react-native-scripts` failed)

from create-react-native-app.

viniciusCamargo avatar viniciusCamargo commented on May 22, 2024

I tried to install at work with Node 7.6.0 and it's working, but I can't load it in my device with QR code.

Something went wrong.
Could not load exp://my_ip. Network response timed out.

from create-react-native-app.

rtpm avatar rtpm commented on May 22, 2024

@viniciusCamargo

The same for me, though when testing via http://my_ip:19000 request I get (assuming) a proper json response for handling content by expo app.

Update: This may be a problem with docker. I've redirected 2 ports (19000 & 19001, but expo app is still trying to connect to my docker ip), so my problem might not be related to this issue.

from create-react-native-app.

anp avatar anp commented on May 22, 2024

@viniciusCamargo @rtpm are your phone and computer on the same local network?

from create-react-native-app.

rtpm avatar rtpm commented on May 22, 2024

@dikaiosune

Yes, they are on the same network. My docker (internal ip) is 172.17.0.2, and this ip is included in the QR code.. this won't work as it needs to connect to my docker host LAN ip: 192.168.10.16
Even If I try to point url exp://192.168.10.16:19000 (both 19000 & 19001 ports forwarding in docker run set) I am unable to connect.

This is the content of http://192.168.10.16:19000 response.

{"sdkVersion":"14.0.0","name":"app-test","slug":"app-test","version":"0.1.0","xde":true,"developer":{"tool":"crna"},"packagerOpts":{"hostType":"tunnel","lanType":"ip","dev":true,"strict":false,"minify":false,"urlType":"exp","urlRandomness":null},"bundleUrl":"http://172.17.0.2:19001/./node_modules/react-native-scripts/build/bin/crna-entry.bundle?platform=ios&dev=true&strict=false&minify=false&hot=false&assetPlugin=expo/tools/hashAssetFiles","debuggerHost":"172.17.0.2:19001","mainModuleName":"./node_modules/react-native-scripts/build/bin/crna-entry","logUrl":"http://172.17.0.2:19000/logs","id":"@anonymous/app-test-f1c15a88-37cb-429a-94d5-9bfc040bce32"}

Some env for setting the ip would maybe solve it?

Thanks

from create-react-native-app.

anp avatar anp commented on May 22, 2024

I can see using an environment variable for the IP address, but is there a reason you need to run it in docker? CRNA should work on Windows, Linux, and Mac.

from create-react-native-app.

rtpm avatar rtpm commented on May 22, 2024

@dikaiosune

With 337 MB image (all stuff for running create-react-native-app) included I can move it between my boxes easily. (Alpine Linux). Unfortunately I am unable to run create-react-native-app on windows 10 (using cmd & git bash). Now it's complaining about Visual C++/ .NET dependency. Not creating an issue yet as I'm not sure If I do all the things properly :-)

from create-react-native-app.

viniciusCamargo avatar viniciusCamargo commented on May 22, 2024

@dikaiosune yep! same network here...

from create-react-native-app.

anp avatar anp commented on May 22, 2024

Update on the Windows installation issues: I've released 0.0.5 of create-react-native-app which asks yarn to ignore optional dependencies (which is where this error is arising), but yarn does not appear to be respecting the flag.

from create-react-native-app.

dansha avatar dansha commented on May 22, 2024

uninstalled yarn from machine and tried to create a project.
same result :-(

from create-react-native-app.

anp avatar anp commented on May 22, 2024

I think this may be due to a bug in yarn. I've filed an issue which will either help me discover how I'm using yarn incorrectly, or we can hopefully get it fixed: yarnpkg/yarn#2929

from create-react-native-app.

rtpm avatar rtpm commented on May 22, 2024

Works fine for me using npm (yarn uninstalled)

from create-react-native-app.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.