Node-red freezes running only a few nodes

Yes - the node itself works fine. The BCM lib is installed. I tried this without node-red on my PI and in node-red both worked fine.

tx
Leafboy

Please paste your flow to a reply. if you can ssh into the pi,

  1. do a ‘cd ,node-red’
  2. do ‘ls *.json’ - there should only be one
  3. list that file - i.e ‘cat xxxxxx.json’ where xxxxxx is the name of your file
  4. copy the listing and paste it into a reply making sure to start with a line of three backticks - then paste the json - then a line of three backticks (they are to make sure there are no smart quotes)

Hi zenofmud.

Sorry my late response. On workdays it is quite difficult for me to find some time to answer. Actually there were two json files but this should be my problem flow I attach here. As requested my flows.

[{"id":"bbcf2661.503728","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"b3a94df9.31a9a","type":"tab","label":"Flow 2","disabled":false,"info":""},{"id":"9ef05ec4.baf2b","type":"tab","label":"Flow 3","disabled":false,"info":""},{"id":"ce2c5356.4e0d6","type":"tab","label":"Flow 4","disabled":false,"info":""},{"id":"8278e3fd.99dbd","type":"ui_base","theme":{"name":"theme-light","lightTheme":{"default":"#0094CE","baseColor":"#0094CE","baseFont":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif","edited":true,"reset":false},"darkTheme":{"default":"#097479","baseColor":"#097479","baseFont":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif","edited":false},"customTheme":{"name":"Untitled Theme 1","default":"#4B7930","baseColor":"#4B7930","baseFont":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"},"themeState":{"base-color":{"default":"#0094CE","value":"#0094CE","edited":false},"page-titlebar-backgroundColor":{"value":"#0094CE","edited":false},"page-backgroundColor":{"value":"#fafafa","edited":false},"page-sidebar-backgroundColor":{"value":"#ffffff","edited":false},"group-textColor":{"value":"#1bbfff","edited":false},"group-borderColor":{"value":"#ffffff","edited":false},"group-backgroundColor":{"value":"#ffffff","edited":false},"widget-textColor":{"value":"#111111","edited":false},"widget-backgroundColor":{"value":"#0094ce","edited":false},"widget-borderColor":{"value":"#ffffff","edited":false},"base-font":{"value":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"}}},"site":{"name":"Node-RED Dashboard","hideToolbar":"false","allowSwipe":"false","allowTempTheme":"true","dateFormat":"DD/MM/YYYY","sizes":{"sx":48,"sy":48,"gx":6,"gy":6,"cx":6,"cy":6,"px":0,"py":0}}},{"id":"bcf37914.ac8d48","type":"ui_tab","name":"Tab 1","icon":"dashboard","order":1},{"id":"fdbc36d.08f34c8","type":"ui_group","z":"","name":"Temp","tab":"bcf37914.ac8d48","order":1,"disp":true,"width":"6","collapse":false},{"id":"dfb48b63.a6b248","type":"ui_group","z":"","name":"Temp2","tab":"bcf37914.ac8d48","order":2,"disp":true,"width":"6","collapse":false},{"id":"4e02d8c4.5ff3e8","type":"ui_group","z":"","name":"Temp3","tab":"bcf37914.ac8d48","order":3,"disp":true,"width":"6","collapse":false},{"id":"f4e3266e.715ae8","type":"ui_group","z":"","name":"Heizraum","tab":"","order":2,"disp":true,"width":"6","collapse":false},{"id":"50ee3a67.0218c4","type":"inject","z":"bbcf2661.503728","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":215,"y":50,"wires":[["4337a16b.d10e6"]]},{"id":"4337a16b.d10e6","type":"sensor-ds18b20","z":"bbcf2661.503728","name":"","topic":"","sensorid":"28-031724c7b4ff","timer":"1","repeat":false,"x":420,"y":43,"wires":[["84ebad94.80427","8df809f7.79e278"]]},{"id":"84ebad94.80427","type":"ui_gauge","z":"bbcf2661.503728","name":"","group":"fdbc36d.08f34c8","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":640,"y":42,"wires":[]},{"id":"8df809f7.79e278","type":"debug","z":"bbcf2661.503728","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":650,"y":133,"wires":[]},{"id":"26af442b.42416c","type":"inject","z":"bbcf2661.503728","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":236,"y":249,"wires":[["2fe99d1.1efb462"]]},{"id":"2fe99d1.1efb462","type":"sensor-ds18b20","z":"bbcf2661.503728","name":"","topic":"","sensorid":"28-021481030cff","timer":"1","repeat":false,"x":441,"y":242,"wires":[["987d1a5.8cb8ce8","ef9551cb.43dac"]]},{"id":"987d1a5.8cb8ce8","type":"ui_gauge","z":"bbcf2661.503728","name":"","group":"fdbc36d.08f34c8","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":661,"y":241,"wires":[]},{"id":"ef9551cb.43dac","type":"debug","z":"bbcf2661.503728","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":671,"y":332,"wires":[]},{"id":"93789cfb.8b4f8","type":"inject","z":"bbcf2661.503728","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":230,"y":411,"wires":[["c482171a.831b58"]]},{"id":"c482171a.831b58","type":"sensor-ds18b20","z":"bbcf2661.503728","name":"","topic":"","sensorid":"28-02148106aeff","timer":"1","repeat":false,"x":435,"y":404,"wires":[["7b8e568c.e4e248","58a444bc.e8dfec"]]},{"id":"7b8e568c.e4e248","type":"ui_gauge","z":"bbcf2661.503728","name":"","group":"fdbc36d.08f34c8","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":655,"y":403,"wires":[]},{"id":"58a444bc.e8dfec","type":"debug","z":"bbcf2661.503728","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":665,"y":494,"wires":[]},{"id":"a3470205.a4c7c","type":"inject","z":"bbcf2661.503728","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":229,"y":563,"wires":[["dcefc28b.c7d0e"]]},{"id":"dcefc28b.c7d0e","type":"sensor-ds18b20","z":"bbcf2661.503728","name":"","topic":"","sensorid":"28-031724c747ff","timer":"1","repeat":false,"x":434,"y":556,"wires":[["5104294.e4acad8","fe4a2469.195f98"]]},{"id":"5104294.e4acad8","type":"ui_gauge","z":"bbcf2661.503728","name":"","group":"fdbc36d.08f34c8","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":654,"y":555,"wires":[]},{"id":"fe4a2469.195f98","type":"debug","z":"bbcf2661.503728","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":664,"y":646,"wires":[]},{"id":"d0e31a17.69a2c8","type":"inject","z":"b3a94df9.31a9a","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":211,"y":73,"wires":[["928e7edc.c73f6"]]},{"id":"928e7edc.c73f6","type":"sensor-ds18b20","z":"b3a94df9.31a9a","name":"","topic":"","sensorid":"28-031724c7b4ff","timer":"1","repeat":false,"x":416,"y":66,"wires":[["3fa8050a.70f48a","7e257062.19961"]]},{"id":"3fa8050a.70f48a","type":"ui_gauge","z":"b3a94df9.31a9a","name":"","group":"dfb48b63.a6b248","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":636,"y":65,"wires":[]},{"id":"7e257062.19961","type":"debug","z":"b3a94df9.31a9a","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":646,"y":156,"wires":[]},{"id":"9e6a573f.d61b68","type":"inject","z":"b3a94df9.31a9a","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":232,"y":272,"wires":[["8cb4f0aa.8c40d"]]},{"id":"8cb4f0aa.8c40d","type":"sensor-ds18b20","z":"b3a94df9.31a9a","name":"","topic":"","sensorid":"28-021481030cff","timer":"1","repeat":false,"x":437,"y":265,"wires":[["1c763f68.a9f651","9abbd13.86fd53"]]},{"id":"1c763f68.a9f651","type":"ui_gauge","z":"b3a94df9.31a9a","name":"","group":"dfb48b63.a6b248","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":657,"y":264,"wires":[]},{"id":"9abbd13.86fd53","type":"debug","z":"b3a94df9.31a9a","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":667,"y":355,"wires":[]},{"id":"a28843b.8b81ec","type":"inject","z":"b3a94df9.31a9a","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":226,"y":434,"wires":[["af3b4a57.91a008"]]},{"id":"af3b4a57.91a008","type":"sensor-ds18b20","z":"b3a94df9.31a9a","name":"","topic":"","sensorid":"28-02148106aeff","timer":"1","repeat":false,"x":431,"y":427,"wires":[["2fe55cb2.886bf4","d32ace27.5808f"]]},{"id":"2fe55cb2.886bf4","type":"ui_gauge","z":"b3a94df9.31a9a","name":"","group":"dfb48b63.a6b248","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":651,"y":426,"wires":[]},{"id":"d32ace27.5808f","type":"debug","z":"b3a94df9.31a9a","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":661,"y":517,"wires":[]},{"id":"ac3783f9.fecab","type":"inject","z":"b3a94df9.31a9a","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":225,"y":586,"wires":[["d5dd6bf2.2b8a88"]]},{"id":"d5dd6bf2.2b8a88","type":"sensor-ds18b20","z":"b3a94df9.31a9a","name":"","topic":"","sensorid":"28-031724c747ff","timer":"1","repeat":false,"x":430,"y":579,"wires":[["32f3abec.a08724","4c3771e0.9dbec"]]},{"id":"32f3abec.a08724","type":"ui_gauge","z":"b3a94df9.31a9a","name":"","group":"dfb48b63.a6b248","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":650,"y":578,"wires":[]},{"id":"4c3771e0.9dbec","type":"debug","z":"b3a94df9.31a9a","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":660,"y":669,"wires":[]},{"id":"d3083434.df8a28","type":"inject","z":"9ef05ec4.baf2b","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":234,"y":110,"wires":[["e17aa4d.7eab758"]]},{"id":"e17aa4d.7eab758","type":"sensor-ds18b20","z":"9ef05ec4.baf2b","name":"","topic":"","sensorid":"28-031724c7b4ff","timer":"1","repeat":false,"x":439,"y":103,"wires":[["bb93d308.ad001","add9d5ff.52f2e8"]]},{"id":"bb93d308.ad001","type":"ui_gauge","z":"9ef05ec4.baf2b","name":"","group":"4e02d8c4.5ff3e8","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":659,"y":102,"wires":[]},{"id":"add9d5ff.52f2e8","type":"debug","z":"9ef05ec4.baf2b","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":669,"y":193,"wires":[]},{"id":"ec8d1203.f8826","type":"inject","z":"9ef05ec4.baf2b","name":"","topic":"","payload":"","payloadType":"date","repeat":"10","crontab":"","once":false,"onceDelay":0.1,"x":255,"y":309,"wires":[["553d53dd.61714c"]]},{"id":"553d53dd.61714c","type":"sensor-ds18b20","z":"9ef05ec4.baf2b","name":"","topic":"","sensorid":"28-021481030cff","timer":"1","repeat":false,"x":460,"y":302,"wires":[["a583f889.e05848","13e78694.3c5ce9"]]},{"id":"a583f889.e05848","type":"ui_gauge","z":"9ef05ec4.baf2b","name":"","group":"4e02d8c4.5ff3e8","order":0,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"units","format":"{{value}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":680,"y":301,"wires":[]},{"id":"13e78694.3c5ce9","type":"debug","z":"9ef05ec4.baf2b","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"payload","x":690,"y":392,"wires":[]},{"id":"19a18ff5.25a5b","type":"ui_text","z":"ce2c5356.4e0d6","group":"4e02d8c4.5ff3e8","order":2,"width":"0","height":"0","name":"Zeit","label":"","format":"<h1>{{msg.payload}}</h1>","layout":"col-center","x":623.8333282470703,"y":100,"wires":[]},{"id":"91884d61.f1ee4","type":"debug","z":"ce2c5356.4e0d6","name":"","active":false,"tosidebar":true,"console":true,"tostatus":false,"complete":"true","x":620.8333282470703,"y":158.33330535888672,"wires":[]},{"id":"53926bbf.e0be34","type":"inject","z":"ce2c5356.4e0d6","name":"","topic":"Zeit","payload":"","payloadType":"date","repeat":"1","crontab":"","once":false,"onceDelay":0.1,"x":85,"y":101.99996948242188,"wires":[["d649dbeb.03afc8","b5b43a69.3db2a8","29996ef9.679fc2"]]},{"id":"ff7c2f88.b96f9","type":"ui_text","z":"ce2c5356.4e0d6","group":"4e02d8c4.5ff3e8","order":1,"width":"6","height":"2","name":"Datum","label":"Datum","format":"<h2>{{msg.payload}}</h2>","layout":"col-center","x":601.0000152587891,"y":372.49999237060547,"wires":[]},{"id":"315252f6.b8288e","type":"debug","z":"ce2c5356.4e0d6","name":"","active":false,"tosidebar":true,"console":true,"tostatus":false,"complete":"true","x":618.0000152587891,"y":424.8333053588867,"wires":[]},{"id":"d649dbeb.03afc8","type":"moment","z":"ce2c5356.4e0d6","name":"","topic":"","input":"","inputType":"msg","inTz":"Europe/Vienna","adjAmount":0,"adjType":"days","adjDir":"add","format":"HH:mm:ss","locale":"de_AT","output":"","outputType":"msg","outTz":"Europe/Vienna","x":327.8333282470703,"y":102.33334350585938,"wires":[["19a18ff5.25a5b","91884d61.f1ee4"]]},{"id":"29996ef9.679fc2","type":"moment","z":"ce2c5356.4e0d6","name":"","topic":"","input":"","inputType":"msg","inTz":"Europe/Vienna","adjAmount":0,"adjType":"days","adjDir":"add","format":"DD. MMMM YYYY","locale":"de_AT","output":"","outputType":"msg","outTz":"Europe/Vienna","x":316.00001525878906,"y":323.99999237060547,"wires":[["ff7c2f88.b96f9","315252f6.b8288e"]]},{"id":"44e3dfe2.7b5ef","type":"ui_text","z":"ce2c5356.4e0d6","group":"4e02d8c4.5ff3e8","order":2,"width":"0","height":"0","name":"US Zeit","label":"","format":"<h1>{{msg.payload}}</h1>","layout":"col-center","x":629.0000152587891,"y":218.99996185302734,"wires":[]},{"id":"cf54998f.f75f08","type":"debug","z":"ce2c5356.4e0d6","name":"","active":false,"tosidebar":true,"console":true,"tostatus":false,"complete":"true","x":616.0000152587891,"y":277.33326721191406,"wires":[]},{"id":"b5b43a69.3db2a8","type":"moment","z":"ce2c5356.4e0d6","name":"","topic":"","input":"","inputType":"msg","inTz":"America/Miami","adjAmount":0,"adjType":"days","adjDir":"add","format":"HH:mm:ss","locale":"en-US","output":"","outputType":"msg","outTz":"ETC/GMT+4","x":323.00001525878906,"y":221.33330535888672,"wires":[["44e3dfe2.7b5ef","cf54998f.f75f08"]]},{"id":"a309df66.b39ba","type":"rpi-dht22","z":"ce2c5356.4e0d6","name":"","topic":"rpi-dht22","dht":22,"pintype":1,"pin":4,"x":297,"y":546,"wires":[["2877a0b6.6b773","7ea4f32c.24568c","fd2a045e.ad7698"]]},{"id":"fd2a045e.ad7698","type":"debug","z":"ce2c5356.4e0d6","name":"Info","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"true","x":555,"y":620,"wires":[]},{"id":"7ea4f32c.24568c","type":"ui_gauge","z":"ce2c5356.4e0d6","name":"Feuchte","group":"4e02d8c4.5ff3e8","order":2,"width":0,"height":0,"gtype":"gage","title":"Feuchte","label":"%RH","format":"{{humidity}}","min":0,"max":"100","colors":["#2505f7","#6ae600","#ca3838"],"seg1":"30","seg2":"50","x":565,"y":560,"wires":[]},{"id":"2877a0b6.6b773","type":"ui_gauge","z":"ce2c5356.4e0d6","name":"Temperatur","group":"4e02d8c4.5ff3e8","order":1,"width":0,"height":0,"gtype":"gage","title":"Temperatur","label":"°C","format":"{{payload}}","min":"-20","max":"50","colors":["#002fb5","#71e600","#ca3838"],"seg1":"20","seg2":"28","x":575,"y":500,"wires":[]},{"id":"6b07fc8c.2f13a4","type":"inject","z":"ce2c5356.4e0d6","name":"","topic":"","payload":"","payloadType":"date","repeat":"5","crontab":"","once":false,"onceDelay":0.1,"x":75,"y":540,"wires":[["a309df66.b39ba"]]}]

I hope you can find a solution for me. Thank you very much for your time it is much appreciated.
leafboy

Ok, so you have 10 ds18b20 sensors and you are measuring them every second and sending the result to a gauge. Why? Does your environment change that rapidly? Try changing then to read once a minute or every 5 minutes.

Secondly, on Flow 4, you display the time every second…do you really need to? Could just display the HH:MM?

I would change the interval for reading the sensors to every 5 minutes and see how that works out.

Having 10 readings per second and send them to a gauges is reason enough to freeze node red???

From other side… DHT sensors for me are giving cheat readings, better to consider the use of BMP280 or similar.

C[quote=“davidcgu, post:25, topic:1007”]
Having 10 readings per second and send them to a gauges is reason enough to freeze node red???
[/quote]

It shouldn’t but when someone says their machine hangs you need to eliminate things. Since the 10 ds18b20 worked and the hang came after adding the dht22, it probably has something to do with it but I want to see what happens when limiting the ds18b20’s

I reduced the readings to every minute and all is working fine now. Of course I don’t need to know the temperature every second and the HH:mm is also sufficient. I just want to do more readings per minute because it is nicer to see the changes during setup of the sensors. Nevertheless it is wondering me how can I realize i.e. a pulse counter where many pulses will arrive per second. Is there a special node to count all these signals. Regarding DHT sensor it was just laying around so I did not care to get a BMP280. Besides it is not that critical if there are some cheat readings. Next thing I will add my DHT sensor and let you know if it is still working.
Thanks a lot for all your thounghts.
leafboy

You probably need to inspect the insides of the code that actually does the read of the sensors - as quite often they have a “settle time” to allow the ADC to do it’s work and that can often be defaulted to a second or so…(because… why not…) in which case reading every second may start to back up requests until the memory/stack pops…

Same may well be true of the DHT code - so again worth checking the underlying code if you do want to read fast at some point.

Good article here (though it is about Arduino - but you get the idea) - https://www.scargill.net/reading-dallas-ds18b20-chips-quickly/

10 sensors of DS18B20 reading every minute works fine. As soon as I added the DHT22 sensor my Pi freezes again even though my reading is at every minute. When setup the DHT22 alone it works fine as well. I read the previous article but honestly it won’t help me much because I can’t read that code. Any other ideas how I could integrate the DHT22 sensor to my 10 other sensors?

Tx
Leafboy

  1. How are the sensors connected? i.e. are all the ds18b20’s on one or many circuits?
  2. what version of the BCM2835 library did you install?
  3. what version of NR? (You reported v8.11.3 but that is a version of node.js not node-red)
  4. what happens if you remove the code reading the ds18b20’s and just have the dht22?

interesting… I just installed your flows and it hangs my Pi too. I’ll take a deeper look.

Sorry - but I am glad to hear that. Here my answers to your previous post:

  • All my DS18B20 sensors are on one 4K7 resistor on Pin 4 of my Pi. (1-wire of course)
  • BCM2835-1.56 is the current lib and installed
  • Node-Red Version is V0.18.7
  • I’ll try out and let you know.

For the time being thanks for your assistance
Leafboy

I added a DHT22 sensor and even if I put no timestamp to all my DS18B20 the PI hangs. Actually all the DS18B20 are inactive it hangs.

Wow, 10 x DS18B20 on a 4.7k operating at 3.3v? Do they work? 4.7k is too high even for one device when you do the sums. Better to go with 1.5k but even then I would have thought that more than two or three devices would be pushing the boundaries.

yes - they work perfectly. I never found any docs who limited the number of sensors. Of course I did not verify the displayed value but it seems quite ok.

Is the 4.7k up to 3.3v or 5?

I connected the sensors to 3.3V

Do you mean you connected the sensors to pin 4, 3.3v and ground, and the 4.7k between pin 4 and 3.3v?

Yes - exactly. I found docs where they connect a 10k between pin4 (actually GPIO4 not pin 4) and 3.3V

OK, well if it works it will probably keep working.
If you find the sensors stop working on hot days or cold days then drop the resistor to 1.5k.
I don’t think this is anything to do with the DHT problem.