tidev / gittio

Search & Install all Titanium Modules and Alloy Widgets on GitHub
http://gitt.io
Other
24 stars 19 forks source link

Module installation error on node 4.2.3 #108

Closed nazrdogan closed 8 years ago

nazrdogan commented 8 years ago

I m using Node 4.2.3 When trying to install I m getting this error.

   [ERROR] gittio requires the global Titanium CLI: [sudo] npm install -g titanium

But I m aldready installed Titanium.

    titanium -v
    node) sys is deprecated. Use util instead.
    5.0.5

I look at gittio source code timodules.list function returns null

FokkeZB commented 8 years ago

Mm, maybe because of that error timodules isn't able to read the JSON result from the Ti CLI. Let me check if we need to update the Ti CLI to work with 4.2.x still or if this has already been fixed.

FokkeZB commented 8 years ago

Could you reinstall the Ti CLI? I run node 4.2.3 as well but I don't get that warning when I run ti -v

FokkeZB commented 8 years ago

See https://jira.appcelerator.org/browse/TIMOB-19133

nazrdogan commented 8 years ago

@FokkeZB I reinstall Ti CLI and Gittio but same result. :(

FokkeZB commented 8 years ago

Could you try to delete your local npm cache (sudo rm -rf ~/.npm) and then install again?

nazrdogan commented 8 years ago

I tried but same :(

FokkeZB commented 8 years ago

Weird. Could you do a code search on the titanium dir (probably /usr/local/lib/node_modules) to see where sys is used? Search for both "sys" and 'sys'.

nazrdogan commented 8 years ago

it cannot find anything

nazrdogan commented 8 years ago

I open Titanium npm modules on text editor. and search (node) sys is deprecated. Use util instead. nothing found .its really weird .where is it come

nazrdogan commented 8 years ago

its only found on test files

    /usr/local/lib/node_modules/titanium/node_modules/node-appc/node_modules/.bin/uglifyjs:
5  
6  var UglifyJS = require("../tools/node");
7: var sys = require("util");
8  var yargs = require("yargs");
9  var fs = require("fs");

  /usr/local/lib/node_modules/titanium/node_modules/node-appc/node_modules/request/node_modules/http-signature/node_modules/asn1/tst/ber/writer.test.js:
2  
3  var test = require('tap').test;
4: var sys = require('sys');
5  
6  ///--- Globals

    /usr/local/lib/node_modules/titanium/node_modules/node-appc/node_modules/uglify-js/bin/uglifyjs:
5  
6  var UglifyJS = require("../tools/node");
7: var sys = require("util");
8  var yargs = require("yargs");
9  var fs = require("fs");

      /usr/local/lib/node_modules/titanium/node_modules/node-appc/node_modules/uglify-js/node_modules/uglify-to-browserify/index.js:
  15    if (cache[file]) return makeStream(cache[file])
 16    var uglify = require(file)
  17:   var src = 'var sys = require("util");\nvar MOZ_SourceMap = require("source-map");\nvar UglifyJS = exports;\n' + uglify.FILES.map(function (path) { return fs.readFileSync(path, 'utf8') }).join('\n')
  18  
    19    var ast = uglify.parse(src)

/usr/local/lib/node_modules/titanium/node_modules/request/node_modules/http-signature/node_modules/asn1/tst/ber/writer.test.js:
2  
3  var test = require('tap').test;
4: var sys = require('sys');
5  
6  ///--- Globals

5 matches across 5 files
FokkeZB commented 8 years ago

Yeah, very strange. I've found that as well with another user and reported the issue: https://jira.appcelerator.org/browse/CLI-907

nazrdogan commented 8 years ago

• sudo rm -rf ~/.appcelerator • sudo rm -rf ~/.titanium • sudo npm uninstall -g titanium • sudo npm uninstall -g alloy • sudo npm uninstall -g acs • sudo npm uninstall -g appcelerator • sudo npm install -g appcelerator • appc use latest • appc setup • sudo npm install -g alloy

FokkeZB commented 8 years ago

haha, but now we still don't know where sys was used ;)

nazrdogan commented 8 years ago

yes :) We cannot know anymore

cdrx commented 8 years ago

Did you have TiShadow installed?

nazrdogan commented 8 years ago

yes . its give me (node) sys is deprecated. Use util instead.

cdrx commented 8 years ago

If you uninstall it (or update to tishadow master) the sys / util warning will go away.

nazrdogan commented 8 years ago

Now Titanium not giving util warning .But Tishadow gives. And they are different modules. How can it possible ?

cdrx commented 8 years ago

TiShadow installs a hook into your ~/.titanium/config.json file that appc runs

nazrdogan commented 8 years ago

Hmm now I understand ,thank guy :)