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

clock-timer overwrite don't work #171

Closed
j3k4 opened this issue Aug 13, 2020 · 1 comment
Closed

clock-timer overwrite don't work #171

j3k4 opened this issue Aug 13, 2020 · 1 comment
Assignees
Labels
🐛 bug Something isn't working
Milestone

Comments

@j3k4
Copy link

j3k4 commented Aug 13, 2020

Describe the bug
When overwriting or resetting the payload of the clock-timer node, you always get the error:
"Error: Cannot read property 'overwrite' of undefined"

Except at the inputs:

{
  "topic":"manual", 
  "payload":false
}

and

{
  "topic":"overwrite", 
  "payload":false
}

Logs

13 Aug 21:27:06 - [info] [clock-timer:b9ed1e3f.9dac9] TypeError: Cannot read property 'overwrite' of undefined
    at setExpiringOverwrite (/data/node_modules/node-red-contrib-sun-position/nodes/clock-timer.js:106:85)
    at checkTCPosOverwrite (/data/node_modules/node-red-contrib-sun-position/nodes/clock-timer.js:242:17)
    at clockTimerNode._inputCallback (/data/node_modules/node-red-contrib-sun-position/nodes/clock-timer.js:759:35)
    at clockTimerNode.Node._emitInput (/usr/src/node-red/node_modules/@node-red/runtime/lib/nodes/Node.js:200:18)
    at Immediate._onImmediate (/usr/src/node-red/node_modules/@node-red/runtime/lib/nodes/Node.js:179:33)
    at runCallback (timers.js:705:18)
    at tryOnImmediate (timers.js:676:5)
    at processImmediate (timers.js:658:5)
13 Aug 21:27:06 - [error] [clock-timer:b9ed1e3f.9dac9] Error: Cannot read property 'overwrite' of undefined

Screenshots
Screenshot 2020-08-13 at 18 17 35

Screenshot 2020-08-13 at 18 17 01

System information (please complete the following information):

  • Node Version: 1.1.3
  • Node-Red Version: 1.1.3

Additional context
here is the flow:

[{"id":"a1e7d60c.976b38","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"b9ed1e3f.9dac9","type":"clock-timer","z":"a1e7d60c.976b38","name":"","topic":"","positionConfig":"b750689f.288168","outputs":"1","autoTrigger":false,"autoTriggerTime":"60000","startDelayTime":10000,"storeName":"","overwriteExpire":"3600000","rules":[{"index":0,"name":"","isValid":false,"valid":{},"timeValue":"06:00","timeType":"entered","timeOp":0,"timeOpText":"↥ until","offsetValue":"","offsetType":"none","multiplier":60000,"timeDays":"*","timeMonths":"*","timeOnlyEvenDays":false,"timeOnlyOddDays":false,"timeDateStart":"","timeDateEnd":"","timeMinValue":"","timeMinType":"none","offsetMinValue":"","offsetMinType":"none","multiplierMin":60000,"timeMaxValue":"","timeMaxType":"none","offsetMaxValue":"","offsetMaxType":"none","multiplierMax":60000,"payloadValue":"false","payloadType":"bool","payloadOffsetValue":"","payloadOffsetType":"none","payloadOffsetMultiplier":60000,"payloadFormat":99,"topic":"","validOperandAValue":"","validOperandAType":"none","validOperator":"true","validOperatorText":"is true","validOperandBValue":"","validOperandBType":"num","valid2LogOperator":0,"valid2LogOperatorText":"N/A","valid2OperandAValue":"","valid2OperandAType":"msg","valid2Operator":"true","valid2OperatorText":"is true","valid2OperandBValue":"","valid2OperandBType":"num","description":"<div><i class=\"fa fa-clock-o\" aria-hidden=\"true\"></i> ↥ until <var>06:00</var></div><div><div class=\"indent-payload-text\"><i class=\"fa fa-step-backward\" aria-hidden=\"true\"></i> <span>Payload: </span> <var>false</var></div></div>","timeMinOp":0,"timeMaxOp":0,"importance":0},{"index":1,"name":"","isValid":false,"valid":{},"timeValue":"22:00","timeType":"entered","timeOp":1,"timeOpText":"↧ from","offsetValue":"","offsetType":"none","multiplier":60000,"timeDays":"*","timeMonths":"*","timeOnlyEvenDays":false,"timeOnlyOddDays":false,"timeDateStart":"","timeDateEnd":"","timeMinValue":"","timeMinType":"none","offsetMinValue":"","offsetMinType":"none","multiplierMin":60000,"timeMaxValue":"","timeMaxType":"none","offsetMaxValue":"","offsetMaxType":"none","multiplierMax":60000,"payloadValue":"false","payloadType":"bool","payloadOffsetValue":"","payloadOffsetType":"none","payloadOffsetMultiplier":60000,"payloadFormat":99,"topic":"","importance":0,"validOperandAValue":"","validOperandAType":"none","validOperator":"true","validOperatorText":"is true","validOperandBValue":"","validOperandBType":"num","valid2LogOperator":0,"valid2LogOperatorText":"N/A","valid2OperandAValue":"","valid2OperandAType":"msg","valid2Operator":"true","valid2OperatorText":"is true","valid2OperandBValue":"","valid2OperandBType":"num","description":"<div><i class=\"fa fa-clock-o\" aria-hidden=\"true\"></i> ↧ from <var>22:00</var></div><div><div class=\"indent-payload-text\"><i class=\"fa fa-step-backward\" aria-hidden=\"true\"></i> <span>Payload: </span> <var>false</var></div></div>","timeMinOp":0,"timeMaxOp":0}],"payloadDefault":"true","payloadDefaultType":"bool","payloadDefaultTimeFormat":0,"payloadDefaultOffset":0,"payloadDefaultOffsetType":"none","payloadDefaultOffsetMultiplier":60000,"x":480,"y":280,"wires":[["79932e55.a4172"]]},{"id":"53380497.12490c","type":"inject","z":"a1e7d60c.976b38","name":"mst.resetOverwrite:true","props":[{"p":"resetOverwrite","v":"true","vt":"bool"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":200,"y":180,"wires":[["b9ed1e3f.9dac9"]]},{"id":"79932e55.a4172","type":"debug","z":"a1e7d60c.976b38","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":630,"y":280,"wires":[]},{"id":"f13b3190.26a54","type":"inject","z":"a1e7d60c.976b38","name":"msg.reset:true","props":[{"p":"reset","v":"true","vt":"bool"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":230,"y":220,"wires":[["b9ed1e3f.9dac9"]]},{"id":"c61a5017.cc992","type":"inject","z":"a1e7d60c.976b38","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"resetOverwrite","payload":"true","payloadType":"bool","x":210,"y":140,"wires":[["b9ed1e3f.9dac9"]]},{"id":"5e6c71bf.60159","type":"comment","z":"a1e7d60c.976b38","name":"reset","info":"","x":190,"y":100,"wires":[]},{"id":"de29da24.df8258","type":"inject","z":"a1e7d60c.976b38","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"manual","payload":"true","payloadType":"bool","x":230,"y":340,"wires":[["b9ed1e3f.9dac9"]]},{"id":"a53f66f5.8e3268","type":"inject","z":"a1e7d60c.976b38","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"manual","payload":"false","payloadType":"bool","x":230,"y":380,"wires":[["b9ed1e3f.9dac9"]]},{"id":"ebe26bb9.e344e8","type":"comment","z":"a1e7d60c.976b38","name":"overwrite","info":"","x":200,"y":300,"wires":[]},{"id":"8a394d81.19852","type":"inject","z":"a1e7d60c.976b38","name":"trigger","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"triggerOnly","payload":"","payloadType":"date","x":250,"y":20,"wires":[["b9ed1e3f.9dac9"]]},{"id":"8adab541.3746d8","type":"inject","z":"a1e7d60c.976b38","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"overwrite","payload":"true","payloadType":"bool","x":230,"y":420,"wires":[["b9ed1e3f.9dac9"]]},{"id":"7f434bcf.b3d8e4","type":"inject","z":"a1e7d60c.976b38","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"overwrite","payload":"false","payloadType":"bool","x":220,"y":460,"wires":[["b9ed1e3f.9dac9"]]},{"id":"b750689f.288168","type":"position-config","z":"","name":"loc","isValide":"true","longitude":"0","latitude":"0","angleType":"deg","timeZoneOffset":"99","timeZoneDST":"0","stateTimeFormat":"3","stateDateFormat":"12"}]
@Hypnos3 Hypnos3 self-assigned this Aug 25, 2020
@Hypnos3 Hypnos3 added the 🐛 bug Something isn't working label Aug 25, 2020
@Hypnos3 Hypnos3 added this to the 1.1.4 milestone Aug 25, 2020
@Hypnos3
Copy link
Collaborator

Hypnos3 commented Aug 25, 2020

will be fixed with the next Version

Hypnos3 added a commit that referenced this issue Aug 25, 2020
- general
  - for a property compare implemented `contain`, `containSome` and `comtainAll` #158

- time inject
  - maybe fix of #159 by better memory cleanup on change
  - added possibility of define which time should be in payload (current or next) #163
  - now setup of payload, topic and additional payload is similar to the inject node of th newest Node-Red Version #172

- within-time
  - fix bug not usable/visible offset for alternate times #170
  - added `withinTimeStart` and `withinTimeEnd` and `withinTime` property to message #156 + #166

- moon-position
  - moon-times now available #161
  - has now a `isUp` _Boolean_ property which gives the state if the moon is Up #162
  - additional properties are `positionAtRise` and `positionAtSet` with position information on rise and set

- clock-time
  - fixed not working overrides #171
@Hypnos3 Hypnos3 closed this as completed Aug 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working
Development

No branches or pull requests

2 participants