警告:检测到递归process.nextTick [英] warning: Recursive process.nextTick detected
问题描述
我有应用程序,我正在开始使用,我只是想运行它,但它崩溃了。它使用grunt,即运行节点服务器,它是Angular.js应用程序。当我运行运行服务器的grunt任务时,以及当我尝试从浏览器访问应用程序时,我收到了来自grunt或node的警告:
(节点)警告:检测到递归process.nextTick。这将在下一个
版本的节点中突破。请使用setImmediate进行递归延期。
很多行和finaly:
util.js:35
var str = String(f).replace(formatRegExp,function(x){
^
RangeError:最大调用堆栈大小超过使用 - 强制继续
由于警告而中止
我尝试在我的应用程序中搜索 process.nextTick
,但它在 node_modules
目录中的很多地方,而不是 src
。
是否可以删除该警告以便我可以运行该应用程序?我搜索这个递归调用?
更新
我使用 ack
,发现这行有三个地方来自这个文件:
$ REPO / node_modules / express / node_modules / connect / node_modules / multiparty / node_modules / readable-stream / node_modules / core-util-is / float.patch
$ REPO / node_modules / grunt-browse r-sync / node_modules / browser-sync / node_modules / connect / node_modules / multiparty / node_modules / readable-stream / node_modules / core-util-is / float.patc h
/ usr / lib / node_modules / bower / node_modules / decompress-zip / node_modules / readable-s tream / nod e_modules / core-util-is / float.patch
但它不是js文件。
这可能是一个烦人的问题。如果您的命名惯例存在重复,Grunt会呕吐。
这会破坏:
grunt.registerTask('foo' ,['foo']);
这不会:
grunt.registerTask('foo',['bar']);
查看此SO帖子: grunt throw检测到递归process.nextTick
I have application, that I'm starting to work with, I'm just want to run it, but it crash. It use grunt, that run node server, it's Angular.js application. When I'm running grunt task that run the server and when I try to access the app from the browser, I've got warnings from grunt or node:
(node) warning: Recursive process.nextTick detected. This will break in the next
version of node. Please use setImmediate for recursive deferral.
lot of lines and finaly:
util.js:35
var str = String(f).replace(formatRegExp, function(x) {
^
RangeError: Maximum call stack size exceeded Use --force to continue.
Aborted due to warnings.
I've try to search in my application for for process.nextTick
but it's in lot of places in node_modules
directory, and not in src
.
Is it possilbe to remove that warning so I can run the application? What code should I search for this recursive call?
UPDATE
I use ack
and found that this line came from this file in 3 places:
$REPO/node_modules/express/node_modules/connect/node_modules/multiparty/node_modules/readable- stream/node_modules/core-util-is/float.patch
$REPO/node_modules/grunt-browser-sync/node_modules/browser-sync/node_modules/connect/node_modu les/multiparty/node_modules/readable-stream/node_modules/core-util-is/float.patch
/usr/lib/node_modules/bower/node_modules/decompress-zip/node_modules/readable-stream/nod e_modules/core-util-is/float.patch
But it's not js file.
This might be a grunt issue. Grunt will vomit if there's repetition in your naming conventions.
This will break:
grunt.registerTask('foo', [ 'foo']);
This will not:
grunt.registerTask('foo', [ 'bar']);
Check out this SO post: grunt throw "Recursive process.nextTick detected"
这篇关于警告:检测到递归process.nextTick的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!