GithubHelp home page GithubHelp logo

Comments (14)

yocontra avatar yocontra commented on July 20, 2024

What version of gulp-util is jshint and jscs using? If they update to the latest the bug has been fixed

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

version bump helped, thank you

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

By the way, is it normal to have such strings in output?

# in gulp-jscs
events.js:72
        throw er; // Unhandled 'error' event

# in gulp-jshint
/Users/vstarkov/projects/webapp-base/node_modules/gulp-jshint/node_modules/map-stream/index.js:103
        throw err
              ^
Error: JSHint failed for: linting.js

from gulp-util.

yocontra avatar yocontra commented on July 20, 2024

@matmuchrapna If the stack was garbage and jshint didn't provide a better stack (or showStack: false) then it is normal

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

@contra but gulp-jscs and gulp-jshit set showStack to false, so it is not normal and a bug?

from gulp-util.

yocontra avatar yocontra commented on July 20, 2024

@matmuchrapna And both are on the newest gulp-util? Can you npm ls gulp-util?

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

@contra Yes, gulp-jscs is already on [email protected] and gulp-jshint is on [email protected] after my PR also this is my npm ls gulp-util output:

webapp-base(gulp-util-bug-demo)$ npm ls gulp-util
[email protected] /Users/vstarkov/projects/webapp-base
├─┬ [email protected]
│ └── [email protected]
├─┬ [email protected]
│ └── [email protected]
└─┬ [email protected]
  ├─┬ [email protected]
  │ └── [email protected]
  └── [email protected]

Also you can clone my webapp-base repo to reproduce the problem.

from gulp-util.

yocontra avatar yocontra commented on July 20, 2024

@matmuchrapna Can you try updating once more? gulp 3.8.7 has the new gulp-util now

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

@contra it helps a little, but this strange error with (when gulp-jshint or gulp-jscs failed on error) still showing in the terminal:

events.js:72
        throw er; // Unhandled 'error' event

For reproduce use linting-test branch of my webapp-base repo.

I tried to find the problem by myself but failed with it, only one I have discovered that this.emit('error', …) cause this bug, but I cannot find event handler for this event or file events.js in my node_modules folders. Where should I continue my investigation?

from gulp-util.

yocontra avatar yocontra commented on July 20, 2024

@matmuchrapna You have to return a stream - https://github.com/matmuchrapna/webapp-base/blob/linting-test/tasks/linting.js#L30

Use the merge-stream module to combine both into one stream, then return that.

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

Thank you

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

is it normal that emitted error logged on this line events.js:L72?

from gulp-util.

yocontra avatar yocontra commented on July 20, 2024

@matmuchrapna That's just how stacktraces work in JS - when you emit an error the emitter itself is in the stack now

from gulp-util.

iamstarkov avatar iamstarkov commented on July 20, 2024

@contra thank you for answer

from gulp-util.

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.