Thank you, Adrian. I fear you are right.
I donât know whatâs going on. Since Iâve updated the random reboots of the camera are gone, but:
- Time of camera is not showing anymore in device settings
- Time of sabotage isnât showing anymore.
But the most annoying part is the following. I have made a few flows:
- If my doorbell is pressed: send a text message in Telegram and send a screenshot in Telegram.
- If there is movement. Send a text message in Telegram and send a screenshot in Telegram.
Before I have updated the camera this worked 100% of the times. Since I have updated, it only works when I manually start one of these flows. To make it more strange: The text messages are coming through all the time, so the flow triggers are working. The screenshots only when I manually start the flow (and it isnât triggered) and like 10% of the times when the flow is triggered.
Meanwhile I have updated the camera multiple times, updated the Homey, restarted everything. But nothing seems to help. The Telegram app isnât updated for over a year, but before I have updated my camera it worked always. I donât know where to search anymore. Do you have any ideas what it can be?
Could you share one of the flows?
I wonder if itâs just a timing issue.
I tried a lot of variations. But it even happens with the most simple one:
If - Camera - motion detected (from onvif app)
Then send Telegram message
Then send Telegram motion snapshot (delay 3 seconds)
*Note: same behavior if I use:
Camera â motion
Camera â snapshot
To send a picture with Telegram
This is the flow I use
https://homey.app/f/6spsCB
Yes I tried that version also. I just tried both in one flow:
- Telegram: text Message
- Telegram: snapshot
- Push notification: snapshot
If I manually start the flow:
I get all 3
If the flow is triggered:
I get 1 and 3
This is very frustrating, since the push notifications are not saved somewhere and I can only see the last one. Itâs strange though, before I have updated my camera it all workedâŠ
Is it possible that it has something to do with the time which is not showing under the camera anymore?
Probably itâs something with the Telegram app, which doesnât seem to be maintained. Very unfortunate, this was one of the functions I used most with this cameraâŠ
That does seem really strange. If you reverse the order of 2 and 3 does it make a difference?
Are you triggering off the Motion Snapshot Ready?
Order doesnât matter unfortunately.
I tried to trigger on that as well. Exact same behavior. Itâs really strange! I tried really everything, and run out of options.
I still find it so weird that if I start the flow myself, it all works. I also tried other triggers in the flow, but all the sameâŠ
Tonight it worked randomly two times, triggered on motion. And 6 times it didnât send a picture, but always send the text.
I also tried to start a flow from within a flow (to try to emulate my manual start). Same strange outcome.
Itâs really strange and I share your frustration as I canât think why this should happen.
It seems the image is being captured as it is being sent via the push notification. By using the Motion Snapshot Ready trigger there shouldnât be any timing issues. The only thing I can think of is the image itself is sometimes not compatible but that doesnât make sense when it is reliable when manually triggered.
I will ask around to see if anyone has any suggestions.
I donât think itâs directly related, as in the cause of the image issue, but could be another symptom of the underlying issue.
Could you set the log to Full Information and send it me after triggering motion.
Really appreciate your effort!
Just send the full information log. Before I send it, I noticed these notifications in the log from the onvif app.
Those messages mean a new trigger came in before it had time to download the previous image.
Looking at the time stamps they are coming in quite frequently. Maybe that is causing an issue where an image that is being sent is overwritten before it completely transfers. I will need to look at the code to refresh my memory about how I did it. If it looks like it is then I will need to think of some workaround but I am not aware of anyway to know if an image is being sent.
I will let you know if I confirm or disprove my hypothesis.
I have published a new test version ONVIF Camera | Homey
I have tried two things in this version to solve the problem with Telegram.
- The image file is now unlinked before downloading it again. The hope is that it will prevent the image overwriting an image that is being sent to Telegram.
- Add a Minimum On Time. This will also limit the time beteen image captures so it can be used to ensure time is given to send each image to Telegram before a new image is captured by another trigger.
I have been testing with Telegram for a few days and I couldnât get it to go wrong with my cameras even before the changes so I donât know if it will fix your problem.
Let me know if it helps.
I was so happy when you released it. Everything worked again. Unfortunately that feeling disappeared after a few hours again. I did extensive testing and canât wrap my head around whatâs going on.
- First everything worked and then suddenly everything stopped and strangely at 20:00 UTC it worked again for a while.
- Manual starting flows did send a telegram text message, the push message from homey worked, but no picture in Telegram.
- I removed the Telegram app, made a new bot and everything, same behavior. Telegram log says itâs being send.
It seems so random. Right now I can make a flow where the push message picture is receiving, but not in Telegram. That will probably work in an hour again⊠It seems somehow that time has influence on whatâs going on.
When itâs working, how frequently do you get images into Telegram?
I occasionally get a situation where the image doesnât appear in the notification bar but it does show in the history of Telegram. That is obviously an issue with Telegram.
With the new setting you can restrict the number of images as the minimum On time also defines the minimum time between images. It might be worth increasing that to see if it helps.
If itâs working I can get multiple images per minute in Telegram. Thatâs working fine then.
Today: Zero images in Telegram and push notifications worked perfectly.
Itâs the function I used most from Homey⊠It all started after I have updated the camera because it rebooted at random times (and after a reboot, this problem occurred). At that time it was fixable with a restart of the app.
The only big difference I noticed is that my camera via Onvif is not giving the time anymore. Could this be an issue with a new onvif version?
Edit: today also manual triggering is not showing the image in Telegram, but only in push message
If you set the minumim on time to 15 seconds and it still doesnât work then I am completly out of ideas.
That seting should gurantee that all images are sent before a new one is captured and that is the only thing I can thnk of that is happening.
Unfortunatley, Homey has no file locking mechanaism so there is no way to know if a file is being transmitted when a new image is written.
I really appreciate your help. I also donât understand it anymore. I have tested literally everything and now itâs not working at all anymore. Text messages are received 100% and images at this moment never. The telegram log says its been send, but I donât receive it though.
If I make a flow: âMotion snapshot readyâ and I manually start this one. I receive an image with the Homey logo. Thatâs the only thing I still receive⊠Strange thing also is that the push message is working all the time.
I canât find anything strange. Seems like I am hitting a bug somewhere, but I donât know where I should look for it. At this moment I donât see the âEvent STILL processing last image (Camera)â anymore. But it doesnât seem that this was the problem. I have also changed the minimum on time, but no difference.
Strange thing I find is that it started when I have updated my camera. My camera had a bug where it rebooted at random times. After the reboot, I had this exact same behavior, but I was always able to fix it by either restarting the camera app.
Telegram log with normal image (snapshot):
4:47:04 PM: Response:
4:47:01 PM: get stream
4:47:01 PM: [SEND IMAGE] {âtoâ:{âimageâ:âhttps://telegram.org/img/t_logo.png",ânameâ:âUsernameâ,âchat_idâ:chatid},âdroptokenâ:"homey:image:random tokenâ}
Telegram log with âMotion snapshot readyâ (when this is not available and I receive the Homey logo):
4:52:38 PM: get stream
4:52:38 PM: [SEND IMAGE] {âtoâ:{âimageâ:âhttps://telegram.org/img/t_logo.png",ânameâ:âUsernameâ,âchat_idâ:chatid},âdroptokenâ:"homey:image:random tokenâ}
The empty response is remarkable. Do you also have this when sending a snapshot to Telegram?
Iâve only been using Telegram to test for the problem you are experiencing so I donât have a lot of experience with it.
However, the images from my cameras have appeared in Telegram every time.
I understand. I know for sure now something is going wrong. If I send a Sonos picture to Telegram, itâs working and also there is no response in the telegram log.
If I look into the telegram code on git I see:
Blockquote
if(!response.ok) {
console.log(âResponse:â, await response.text());
return false;
}
So itâs going wrong, but logging isnât saying whatâs going wrong because answer is empty. Unfortunately this app doesnât seem to be developed anymore.