grunt-saucelabs icon indicating copy to clipboard operation
grunt-saucelabs copied to clipboard

[ERROR] this.key is not a function

Open jnrepo opened this issue 9 years ago • 5 comments

>> TypeError: this.key is not a function
>>     at Job.start (/Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/Job.js:69:43)
>>     at getResult (/Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/TestRunner.js:113:10)
>>     at _combinedTickCallback (internal/process/next_tick.js:67:7)
>>     at process._tickCallback (internal/process/next_tick.js:98:9)
>> From previous event:
>>     at TestRunner.runTest (/Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/TestRunner.js:170:8)
>>     at runJob (/Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/utils.js:51:31)
>> From previous event:
>>     at /Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/utils.js:55:10
>>     at /Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/TestRunner.js:76:18
>>     at Array.map (native)
>>     at .<anonymous> (/Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/TestRunner.js:75:30)
>>     at Array.map (native)
>>     at TestRunner.runTests (/Users/joonheo/projects/studio/node_modules/grunt-saucelabs/src/TestRunner.js:74:8)
>>     at /Users/joonheo/projects/studio/node_modules/grunt-saucelabs/tasks/saucelabs.js:131:27

so I started to get an error that looks like this. I found out that if you change these two lines, it'll fix the issue. However, I'm not sure if this is the correct way to do this

line 1 https://github.com/axemclion/grunt-saucelabs/blob/master/src/Job.js#L68

line 2 https://github.com/axemclion/grunt-saucelabs/blob/master/src/Job.js#L144

jnrepo avatar Aug 02 '16 21:08 jnrepo

I ran into this as well, looks like it originates from the fix to #203.

emmettbutler avatar Aug 16 '16 18:08 emmettbutler

Encountered this same thing. I solved it by turning my key option from a string to a function that returns that same string.

unindented avatar Sep 02 '16 09:09 unindented

I turned my key option into a function as well. Hopefully this gets fixed soon or they update the documentation.

lotrgollum avatar Sep 12 '16 18:09 lotrgollum

This is still an issue in 9.0.0.

Is there any plan to fix this @axemclion?

evilaliv3 avatar Dec 01 '17 08:12 evilaliv3

@evilaliv3 I am not maintaining the project anymore - @Jonahss was. If you have a PR that works, I would be glad to merge that in !!

axemclion avatar Dec 04 '17 23:12 axemclion