agsh / onvif

ONVIF node.js implementation
http://agsh.github.io/onvif/
MIT License
693 stars 236 forks source link

Issue #113 : follow up ONVIF specs for getVideoEncoderConfigurationOp… #114

Closed bl0ggy closed 4 years ago

bl0ggy commented 5 years ago

Issue #113 : follow up ONVIF specs for getVideoEncoderConfigurationOptions

Takes either a video encoder configuration token or a media profile token or both or none. Do not force using token.

bl0ggy commented 5 years ago

Is that failure my fault ? How to debug it ? Actually on my Linux (ubuntu 14.04, npm 5.5.1, node 6.4.0) when I run npm run-script test I always have a few test fails, and sometimes (randomly) more than 10 other tests fail. The coverage summary gave me that error only once, for an unknown reason. The rest of the time it just returns this :

/home/me/onvif/node_modules/mocha/lib/runner.js:684
        test.state = STATE_PASSED;
                   ^

TypeError: Cannot set property 'state' of undefined
    at /home/me/onvif/node_modules/mocha/lib/runner.js:684:20
    at done (/home/me/onvif/node_modules/mocha/lib/runnable.js:334:5)
    at /home/me/onvif/node_modules/mocha/lib/runnable.js:435:7
    at /home/me/onvif/test/discovery.js:129:16
    at EventEmitter.<anonymous> (/home/me/onvif/lib/discovery.js:9:5479)
    at tryOnTimeout (timers.js:232:11)
    at Timer.listOnTimeout (timers.js:202:5)

or this :

events.js:165
      throw err;
      ^

Error: Uncaught, unspecified "error" event. (Wrong SOAP message from 192.43.185.66:3702)
    at EventEmitter.emit (events.js:163:17)
    at /home/me/onvif/lib/discovery.js:9:3187
    at parseSOAPString (/home/me/onvif/lib/utils.js:9:5019)
    at Socket.listener (/home/me/onvif/lib/discovery.js:9:2635)
    at emitTwo (events.js:106:13)
    at Socket.emit (events.js:191:7)
    at UDP.onMessage (dgram.js:550:8)

So it is impossible for me to debug :/

chriswiggins commented 5 years ago

Hi @bl0ggy

Can you keep the previous default so we don't break backwards compatibility? I.e when there are no options, send through the previous default token?

coveralls commented 4 years ago

Coverage Status

Coverage decreased (-1.3%) to 87.306% when pulling 4c70b563a2be0d32756b2888f04e0d80ed33be72 on bl0ggy:master into 583d31d9687ff429c572b883c075d8a2ac0c4cf3 on agsh:master.