I think I've found a Telegram bug on the iOS app that causes the bot to send multiple times the same message. The steps to reproduce the problem are:
click on an inline button, type callback
immediately lock the phone screen, before the bot answers
wait a few moments and then unlock the screen
It will be noticed at this point that the bot starts sending the same message numerous times. It is not easy to reproduce, it is important to lock the screen when the bot has not yet answered, so it is easier with bots that take a few moments to respond. Also, in the answer the bot has to send a message (not editing one that already exist).
I use Microsoft Bot Framework to develop the bot, however all the bots give me the same problem, both mine and others developed with other technologies different from mine. For example, I was able to reproduce it on #BotFather too. Sometimes it enters in a loop, and to stop it you have to send any message to the bot.
I use an iPhone 5, iOS version 12.1.2, Telegram version 5.2. I also tried it on an iPhone 8, but not with other versions of Telegram.
I also happen to receive more than 20 identical messages.
I've already contacted Bot Support on Telegram but no one answers me. Is there anyone who experienced the same problem?
On iOS and macOS, when I click on an inline button and switch the client computer (macbook) off (sleep mode) and turn it on my bot receives the last message sent by the user. Each time message_id is the same.
I solve it the following way: when my script sends a request to the Telegram server it receives a response. That response contains a message_id field and I save it.
Any next message must have another message_id. I just compare that number with the stored number and only if the number is other than saved I run the rest part of my script.
You can try my test bot and watch results in google table.
#ios_bug_bot (https://t.me/ios_bug_bot)
https://docs.google.com/spreadsheets/d/1VTx-O1w_-ka1RzGfaVLVBDu0CQxk16QeJTeFYOE4yvo/edit?usp=sharing
The bot source code is here
https://github.com/avtomatron/telegram_bot/blob/master/google_script_bot
Related
Every time when I’m signing into the app or reinstalling app I didn’t receive group message history. I have searched a lot for message archiving in MUC for iOS. Ejabberd doesn’t provide me old messages of the group although I configured setting into the YML file as mentioned in the attached image. I have kept history size of 10. It means at least 10 messages must be fetched every time when I login into the app or reinstall the app but I could not receive 10 messages every-time after reinstalling the app. I’m using Robbiehanson/XMPPFramework for iOS to implement XMPP based chat. I also performed MucSub based MUC to send/receive messages.
The scenario which I have performed:
I’m part of one MUC group. The member of the associated group sent 15 Messages into the group. I have received all those messages when I’m online. Now I am logged out from the group. Deleted the app from the device and reinstalled it into the device with the same login credentials. At this time I could not see the 15 messages which I received earlier. Here I would like to get all 15 Messages even after reinstalling the app into the iOS device.
I have searched on various Stack overflow questions but none of them are helpful to me. Your help will be appreciated.
Maybe you can try joining the room by specifying the history element with the maxstanzas specified.
We have similar case like we need last 3 months history while joining the room, So we mentioned that in history tag, Like below code sample
let historyElement = DDXMLElement(name: "history")
historyElement.addAttribute(withName: "since", stringValue: ((lastDate as NSDate).addingTimeInterval(1).xmppDateTimeString())!)
room.join(usingNickname: userJidString, history: historyElement)
Until yesterday, I was able to broadcast messages across my several google home speakers in my house. I've been using either the assistant-relay project (https://github.com/greghesp/assistant-relay) or the google-assistant-webserver project (https://github.com/AndBobsYourUncle/hassio-addons). Either project worked perfectly for the last year.
Has something changed in the last day/week?
Yesterday, I noticed I could send a command such as "What time is it?", or "What is the weather?", and it would return the appropriate weather or time. However, if I issued a "broadcast" command of text, or even using one of their precanned recorded messages (bed time, movie time, etc), the message was never broadcasted. Additionally, the MyActivity section of google shows that "You asked the Assistant to broadcast a message" and from the SDK.
Has something changed? Are we no longer able todo broadcasting programmatically?
I'm working on an iOS project. For this project I need an authentication system. However, if it's possible I don't want to use already built two-factor authentication systems such as Plivo or Sinch. I want to implement this feature of our application.
For this purpose, I need three things:
My application should get the phone number of the user and send it to server.
Server should send a sms to the number of user and my application should be able to read this message to get authentication code sent by server.
Application should be able to remove messages of this procedure from inbox and outbox of the iPhone used by user.
Now, i'm asking that can I implement this feature? I know this is a weird question but i've searched the Internet all day and could not get a certain answer. Thus I'll appreciate if someone informs me shortly.
Yes, you can that.
Your app can't read SMS messages received through the Messages app. The user would need read the message and note the code. Then switch back to your app where they could then type in the received code.
Your app can't access or modify any SMS messages received through the Messages app. The user would need to delete the message if they wanted to.
I am working on an app that can automatically send a message to some specific ones (either emails or SMS) under some dangerous circumstances.
When someone is in danger, he or she has no time to press the send button. Is it possible for the user to approve sending messages in the app in advance, so the app can automatically send emails or SMS to others without telling the user?
I searched in StackOverflow, but found no similar answers.
This is just for a demo. It does not need to be approved by Apple.
Thanks in advance!
Take a look at the ChatKit framework.
It uses iOS private APIs to do what you want to achieve. Don't try to submit it to Apple though.
With this framework, you can programmatically compose and send text messages through iMessage/SMS.
I am working with a calendar and scheduling application. The requirements are to work in Notes and on Blackberry devices. Currently when I do a send using a NotesDocument, it works fine for the first meeting send on all. However, if you update the meeting, it only sends a correct message to the Notes client. The Blackberry will receive a rich text only e-mail. All MIMEs are correct in sending as well.
Changing this to send using NotesUIDocument will work fine for all instances on the Blackberry but, in Notes gives the error:
Part or all of this meeting is already on your calendar. You must decline those entries first before processing this notice.
I'm kind of at a loss here because what works in one won't work in the other. I am using Notes 8.5.1 and BES 5.0.2. Any help is really appreciated.
Have you considered using a MailOptions field (computed to itself and set via code) to control a send on UI save? That's how mailing works reliably with web apps -- it seems to invoke some voodoo to which I am not privy to add all of the jots and tittles to the right messages to the right parts of the system.