Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot convert undefined or null to object #108

Open
FJLopezGarcia opened this issue Apr 18, 2016 · 5 comments
Open

Cannot convert undefined or null to object #108

FJLopezGarcia opened this issue Apr 18, 2016 · 5 comments

Comments

@FJLopezGarcia
Copy link

FJLopezGarcia commented Apr 18, 2016

Hi team,
I have updated to jscs 3.0.2 and I have updated my gulp task to the following:

const gulp = require('gulp');
const jscs = require('gulp-jscs');
gulp.task('test:jscs', () => {
    return gulp.src(['app/src/**/!(*.min.*).js',
                'app/widgets/**/!(*.min.*).js',
                'app.module.js'])
        .pipe(jscs())
        .pipe(jscs.reporter());
});

Do you now the reason why i am having the following error: Cannot convert undefined or null to object

TypeError: Cannot convert undefined or null to object
    at Function.keys (native)
    at copyConfiguration (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp-jscs/node_modules/jscs/lib/config/configuration.js:1193:12)
    at NodeConfiguration.Configuration._processConfig (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp-jscs/node_modules/jscs/lib/config/configuration.js:474:5)
    at NodeConfiguration.Configuration.load (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp-jscs/node_modules/jscs/lib/config/configuration.js:238:10)
    at StringChecker.configure (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp-jscs/node_modules/jscs/lib/string-checker.js:67:29)
    at Checker.configure (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp-jscs/node_modules/jscs/lib/checker.js:28:39)
    at module.exports (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp-jscs/index.js:35:10)
    at Gulp.<anonymous> (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/gulpfile.js:154:15)
    at module.exports (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp/node_modules/orchestrator/lib/runTask.js:34:7)
    at Gulp.Orchestrator._runTask (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp/node_modules/orchestrator/index.js:273:3)
    at Gulp.Orchestrator._runStep (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp/node_modules/orchestrator/index.js:214:10)
    at Gulp.Orchestrator.start (/Users/franciscojlopez/Documents/GIT/DigitalIntModel_5228Git/Source/Web/Accenture.Dim.Web/node_modules/gulp/node_modules/orchestrator/index.js:134:8)
    at /usr/local/lib/node_modules/gulp/bin/gulp.js:129:20
    at doNTCallback0 (node.js:407:9)
    at process._tickCallback (node.js:336:13)
    at Function.Module.runMain (module.js:477:11)

Here you are my package.json

"devDependencies": {
    "axe-webdriverjs": "^0.2.0",
    "glob": "^4.0.5",
    "gulp": "^3.9.1",
    "gulp-concat": "^2.3.3",
    "gulp-exec": "^2.1.2",
    "gulp-if": "^1.2.5",
    "gulp-ignore": "^2.0.1",
    "gulp-jscpd": "0.0.6",
    "gulp-jscs": "^3.0.2",
    "gulp-jscs-html-reporter": "^0.1.1",
    "gulp-jscs-stylish": "^1.4.0",
    "gulp-jscs-with-reporter": "^1.4.0",
    "gulp-jshint": "^2.0.0",
    "gulp-jshint-html-reporter": "^0.1.3",
    "gulp-jshint-xml-file-reporter": "^0.5.1",
    "gulp-load-plugins": "^0.7.0",
    "gulp-print": "^1.1.0",
    "gulp-protractor": "^2.1.0",
    "gulp-sonar": "^2.0.0",
    "gulp-task-listing": "^1.0.0",
    "gulp-uglify": "^1.5.3",
    "gulp-util": "^3.0.1",
    "gulp-webserver": "^0.9.1",
    "jasmine-expect": "^2.0.2",
    "jasmine-reporters": "^2.1.1",
    "jasmine-spec-reporter": "^2.4.0",
    "jshint": "^2.9.1",
    "jshint-stylish": "^1.0.0",
    "jshint-summary": "^0.4.0",
    "karma": "^0.13.11",
    "karma-chrome-launcher": "^0.2.2",
    "karma-coverage": "^0.5.5",
    "karma-firefox-launcher": "^0.1.7",
    "karma-htmlfile-reporter": "^0.2.2",
    "karma-ie-launcher": "^0.2.0",
    "karma-jasmine": "^0.3.6",
    "karma-jasmine-matchers": "^2.0.1",
    "karma-junit-reporter": "^0.3.7",
    "karma-phantomjs-launcher": "^1.0.0",
    "karma-safari-launcher": "^0.1.1",
    "karma-webdriver-launcher": "~0.2.0",
    "map-stream": "0.0.6",
    "mout": "^0.11.1",
    "mout-lang-type": "^0.6.0",
    "phantomjs": "^1.9.19",
    "phantomjs-prebuilt": "^2.1.3",
    "plato": "^1.2.0",
    "protractor": "^3.0.0",
    "protractor-accessibility-plugin": "^0.1.1",
    "protractor-console-plugin": "^0.1.1",
    "protractor-jasmine2-html-reporter": "0.0.5",
    "protractor-timeline-plugin": "^0.1.4",
    "wiredep": "^2.1.0",
    "yargs": "^1.3.3"
  }
@FJLopezGarcia
Copy link
Author

Fixed... it was my fault

@sylvainpolletvillard
Copy link

Hi @FJLopezGarcia
Have you been able to update gulp-jscs to jscs 3.x easily ? Can you share your work, eventually make a pull request here ?

@ahmedabdellatiff
Copy link

how fix it

@dongtong
Copy link

dongtong commented Jun 5, 2016

@ahmedabdellatiff
You should create .jscsrc file under your workspace, I think you know what it is.

@ahmedabdellatiff
Copy link

@dongtong thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants