kellyselden / broccoli-jscs

Broccoli plugin for jscs
MIT License
16 stars 16 forks source link

broccoli-persistent-filter upstream dep update broke tests #56

Closed kellyselden closed 8 years ago

kellyselden commented 8 years ago

Found here: https://github.com/kellyselden/broccoli-jscs/issues/27#issuecomment-167599851

I figure it has to be an npm dependency change. rimraf and glob dependencies for broccoli-persistent-filter have bumped up in the last month (from 2.4.4 -> 2.5.0 and 5.0.15 -> 6.0.2 respectively). No CHANGELOG on either of those modules so that's just a shot in the dark.

If I revert #41, it goes back to working.

cc @rwjblue @ronco

kellyselden commented 8 years ago

This may help also http://package-hint-historic-resolver.herokuapp.com/?repoBrokenDate=2015-12-28T04%3A00%3A00.000Z&repoUrl=https%3A%2F%2Fgithub.com%2Fstefanpenner%2Fbroccoli-persistent-filter&repoWorkingDate=2015-11-21T22%3A00%3A00.000Z

Turbo87 commented 8 years ago

I suspect that this is related to the use of process.chdir(). I've stepped through this a bit and compared it to the situation in broccoli-jshint with these results:

in Filter.prototype.build() of broccoli-persistent-filter:

// jshint
srcDir = '/Users/tbn/Code/broccoli-jshint/tmp/jshinter-input_base_path-t73QiqFS.tmp/0'

// jscs
srcDir = '/Users/tbn/Code/broccoli-jscs/tests/fixtures/issue-found/tmp/input_base_path-1Q3RukVq.tmp/0'

It looks like the chdir() is causing the tests to use a different tmp folder which, in combination with the symlinks, causes a cycle in the file system:

ENAMETOOLONG: name too long, stat '/Users/tbn/Code/broccoli-jscs/tests/fixtures/issue-found/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/input_base_path-1Q3RukVq.tmp/0/tmp/cache_path-UHjNblW1.tmp'