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)
Related
We are trying to utilise the Microsoft Graph API change notifications to keep track of emails in a users mailbox, however the change notifications that we receive are inconsistent to say the least. For example, I just deleted 7 emails from a users mailbox. We would expect the end result to be that the email is removed from the Inbox and added to the Deleted Items folder, but this only happens sometimes and by seemingly different methods!
Below is the notifications that we received for each email that was deleted (we are using immutable IDs to try make it more simple);
I guess this is an issue with the Microsoft service and not something that we are doing wrong? We have also tried with immutable IDs turned off but were getting equally inconsistent notifications.
(This is now confirmed as a regression in iOS16. A TSI has been opened.)
In the summer, Apple published an informative sample app on sharing objects between iCloud users using Core Data, CloudKit and UICloudSharingController in SwiftUI.
However, adding more participants using UICloudSharingController does not appear to work when used for Core Data with CloudKit.
MRE:
See the Apple sample app linked above.
The same problem also appears when using other sample apps, like the one from RayW.
The problem does not appear in samples that use pure CloudKit, such as this one by Apple.
Reproduction:
Create new share,
Manage share with UICloudSharingController,
Share With More People,
Share using Messages or other service. Succeeds on first attempt, fails on subsequent attempts.
Expectation:
We can use UICloudSharingController to add new participants, using Messages, Mail or other platforms. The link will display correctly on all devices.
Reality:
On iOS16+, attempting to share via Messages engages the "Collaboration" framework and leads to an alert: "An Error Occurred. Unable to start collaboration" (see Image 1). A console warning appears (see below). Triggering this error breaks ANY further shares - the link now cannot be created for Mail and other platforms either (see Image 2). Furthermore, if the first attempt succeeds, the link does not appear correctly on the receiving device (see Image 3).
After further testing, UICloudSharingController also fails in iOS15 - it just dismisses the sheet rather than throw an alert on a compact device. UICloudSharingController is definitely bugged when showing an existing share.
Console logs:
The following console message appears when this issue happens for the first time:
CoreDataCloudKitShare[3672:1242159] systemSharingUIDidSaveShareBlock received error: <CKError 0x28314d8c0: "Server Record Changed"
(14/2004); server message = "client oplock error updating record"; op
= 134D57570A63DF3A; uuid = 8F070F8B-0AC0-4FFE-A52D-154BCBF3196C; container ID = “containerID>
Where "containerID" is the CKContainer ID, like “iCloud.com.company.samples.CoreDataCloudKitShare”. The message does not appear on subsequent attempts to add more people.
Question:
How can this be resolved, so that we can share Core Data records between users using CloudKit and UICloudSharingController?
Images
EDITs:
Other samples of sharing using Core Data and CloudKit exhibit the same problem. Also, console shows a warning when the issue first happens. Post was edited to reflect this.
Question was also posed in Apple Dev Forums
Feedback submitted at FB11623246.
Added conclusions after further testing
24 October 2022: I thought the issue was resolved in iOS16.0.3, but it continues to manifest. It does not matter whether UICloudSharingController is invoked using UIViewController or UIViewControllerRepresentable.
10 November 2022: The issue appears in both Development and Production environments (tested via TestFlight)
15 November 2022: In Ask Apple office hours, this was brought up to the attention of an Apple engineer, who confirmed this as a regression.
25 November 2022: A DTS has been opened. This is now confirmed as a known bug with high priority.
26 December 2022: The bug remains in iOS16.2. An attempt was made to use SWCollaborationView as an alternative to managing collaboration in iOS16. The sharing workflow indeed goes through even on subsequent shares. However, SWCollaborationView does not appear to be compatible with SwiftUI (ugh). See associated SO question
17 January 2023: SWCollaborationView is confirmed as NOT compatible with SwiftUI. FB submitted at FB11941664, please submit FB as well.
25 January 2023: Unfortunately, the issue persists in iOS 16.3.
15 February 2023: Unfortunately, the issue persists in iOS 16.3.1.
Being dealing with both UISharingController and SWCollaborationView for a few month now, I came across this bug (and many others) multiple times wether on my own code or from the Apple samples available.
Calling persistUpdatedShare(_:in:completion:) seems to both save an updated version to the Cloud AND update the locally cached metadata of the share, which is why, after performing persistUpdatedShare, If you keep acting on the initially fetched share, you will get this oplock error, you need to update your code to refetch the lastest CKShare in the persistUpdatedShare completion block.
I couldn't find any easy and clean solution with the current APIs, on top of it SWCollaborationView isn't calling properly its delegates, when it does call them (delegate, cloudSharingDelegate, cloudSharingControllerDelegate) which make it even more difficult.
I am now using SWColaborationView but with major bugs in Catalyst.
I ended up persisting the share using CKSystemSharingUIObserver blocks.
https://developer.apple.com/documentation/cloudkit/cksystemsharinguiobserver
In the systemSharingUIDidSaveShareBlock I persist my share using persistUpdatedShare(_:in:completion:), and, in its completion block I dismiss the presented collaborationView, refetch the share and rebuild the SWCollaborationView and its itemProvider.
Hope this helps
I filed a radar today. You can reference to it as well. The more radars we file, the higher the probability this will get fixed.
FB11990920
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 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
Have any one implemented MUC Light that is Beta released in MongooseIM Chat server for XMPP.
How to fetch fetch following messages when
1) User are offline while they were added as participants of group.
2) Users who are members byt offline and get messages on the muc light group.
I have achieved mod_zero push to trigger the offline message to Users, Also able to store the message in mam_muc_message table in my chat server MySQL database. But how the client will fetch these messages and also be notified with all messages.
Any guidance is much appreciated.
http://mongooseim.readthedocs.io/en/latest/open-extensions/muc_light/
Thanks for suggestion and comments here is how i managed with small limitation.
When user is offline while he was added by some group by others, he wont get this create group stanza as muc-light suggest.
When he come online , there have to be someone atleast who send a group message
When he gets this message I fetch the group configuration and create a new group first and keep this message as pending to process.
Once group created then i link this pending message to this group.
Then I call the MUC light MAM messages as given in 6.2 XEP-0313 Message Archive Management
Then I fetch all the previous messages and add in my database and display on the screen.
The only limitation that is there is after he come online he can't go to server and ask ALL muc-light messages, some how coz the server is not available is thrown if I ask for traditional MAM process to give messages for muclight.****.com group ID so I use as they asked to fetch in above link.
Hope MUC Light Beta is improving ahead more taking this into consideration.