How to create generic ics file which works for gmail, yahoo, outlook and other clients, while send from programming application? - django

I have web application based on django framework. Application creates ICS file by cal python package. We are sending this ICS to differnt clients email ID(gmail, outlook, yahoo etc)
So I am facing problem in below Scenarios
Scenario -
1. Create Event
2. Update all Occurrences or update particular occurrence of event
3. Cancel all Occurrences or cancel particular occurrence of event.
Create -
ICS file is working with Gmail and outlook but not with yahoo when i send this from web application, and if I send the same file from other clients like gmail it creates event in yahoo also.
Update -
Same scenario is applicable for update case. Not working with yahoo.
Cancel -
In cancel case ICS is not working for any client.
I have few point in Cancel file like -
METHOD : CANCEL
UID : Same as sent in create and update case.
Above two are mandatory fields
STATUS, SEQUENCE, RRULE - Is this required?
If SEQUENCE is required then what will be the value of this variable.
Please give your suggestions.

Summary of Answers:
add file header with contents-type = text/calendar.
Validate all ics files and fix the errors such blank lines, line endings etc
For the final cancel of a single instance within a recurring series not working in Yahoo, via email it sounds like Hemendra is issuing a "STATUS:CANCELLED" with the RECURRENCE-ID for the date to be removed. This maybe working with some applications however some may expect the formal way to remove an instance of a date in a series, which is to reissue the event series (RRULE) with the sequence number updated and including the date one wants to exclude as an EXDATE. "The EXDATE property is used to remove instances from a recurrence set defined by an RRULE." https://devguide.calconnect.org/Recurrences/
See also
https://icalendar.org/iCalendar-RFC-5545/3-8-5-1-exception-date-times.html,
icalendar remove an instance from recurrence
What is the correct ics file for editing only one occurrence from the series
Some cautions on EXDATE FORMATS to match
EXDATE recurrence setting being ignored

Related

Getting User Utterance as Text in Amazon Sumerian

I have a Sumerian Host that acts basically as a front-end for a Lex chatbot.
However, in some cases, I need to to some processing based on the actual user utterance (that is, the text of what the user says). Is there a way I can use "Send Audio to Lex" action (or a different one) to get a text version of the user audio (so, to perform speech-to-text)?

How to add external email addresses to AWS WorkMail Group?

I can create a group on the Amazon WorkMail console and add internal users to the group. However, I do not see an option to add external email addresses with different domains.
Any tips on how to do this? Should I just create an email forwarding rule on an internal user?
Unfortunately, at present, this isn't possible (more info below). So, your proposed solution of creating an email forwarding rule is likely the best solution.
One thing to note is that you may want to set up email redirect rather than email forwarding. If you redirect, the end recipient will see the email as coming from the original sender and addressed to the original recipient, as opposed to being forwarded. In WorkMail, you'll find redirect as one of the options, alongside forwarding, when setting up the rule(s).
One additional tip for setting up the redirect/forwarding rule. There's no condition in the rules setup to just forward everything. Because of that, you'll likely want to create 2 rules. The first rule would use the condition has my name in the To box and the second rule would use the condition Does not have my name in the To box. This should have you covered for just redirecting/forwarding everything. Fortunately, you can redirect to multiple destinations, so you can probably get away with just these 2 rules even if you have multiple final destinations.
Additional info about not being able to add external addresses to groups:
An AWS team member has stated that this isn't currently supported in this AWS forum post from 2017:
Indeed, it not possible to add an external email address to a group. I will forward this feature request to the service team.
A possible workaround is to create a redirect rule that redirect emails sent to this group to the external users.
As of today, you still get the following message when adding members to a group (console screenshot):
You can only add users and groups that are enabled for access to Amazon WorkMail.
[Edit, 2021-01-17: Tips on bulk addition of email addresses to a rule]
Bulk addition of email addresses to a rule
Unfortunately, there don't currently appear to be any APIs to create inbox rules programmatically. However, you can copy-paste a large number of emails into a rule.
First, you'll want to export the set of email addresses you have into e.g. a CSV file.
Then, you'll want to append a ; to each email address. The reason for this is that the character is recognized as a separator. If we don't use it, the email rule will interpret the entire pasted text as a single email address. As an example, in Google Sheets, this can be done with CONCATENATE. E.g. =concatenate(A1,";"). Here's a screenshot:
Next, open the email rule, copy the email addresses from the spreadsheet, paste them into the recipients box, and click the To button. In this case, it's 100 emails, so it takes a little bit of time to load:
Once it finishes loading, you'll see checkboxes next to the email addresses, like when you add single email addresses manually.
Make sure to click Ok on the recipients dialog, then click Ok on the rule dialog, and finally click Save changes on the Email Rules Settings panel to ensure everything gets saved.

In Sitecore, how to view the content of the submit queue file?

So in the Sitecore site, in Data/Submit Queue, there is a file without an extension that is representing the content of the Submit Queue.
If you try viewing it as a text file, it shows some content, but there is some strange characters in the mix.
So, has someone made an application to view this file? Is it suppose to be in a specific format that should opened with an application able to view that format?
Extra info: Sitecore 8.0, no there is nothing about it in the control panel or in sitecore/admin.
Mark is right, the submit queue isn't meant for users to view. A couple of months ago, I wrote a post on this exact subject.
https://citizensitecore.com/2016/07/01/xdb-session-info-and-mongodb-availability/
From Akinori Taira, a member of the xDB product team:
In the event that the collections database is unavailable, there is a
special ‘Submit Queue’ mechanism that flushes captured data to the
local hard drive (the ‘Data\Submit Queue’ folder by default). When
the collections database comes back online, a background worker
process submits the data from the ‘Submit Queue’ on disk.
No, you're not meant to be opening the Submit Queue and do anything with it.
It is used by xDB (in your case) to submit data, when the xDB cannot be reached. It will be a format related to MongoDB in some way, but I've never seen any formal documentation for it.
References:
http://sitecoreart.martinrayenglish.com/2015/04/sitecore-xdb-cloud-edition-what-you.html
Sitecore 8.1: Purpose of Submit Queue and MediaIndexing folders under $(dataFolder)
This file contains the analytics data that was not flushed to the Mongo database.
In case xDB collection server is unavailable, Sitecore would/must handle this situation correctly. There is a special 'Submit Queue' mechanism introduced that flushes captured data to local server hard drive ( 'Data\Submit Queue' folder by default ) in case xDB is not available.
When xDB is up again, a background worker would submit the data saved on disk, so no data is lost.
As a quick suggestion on this I recommend you to check whether your MongoDB server is available for your Sitecore instance. Once it becomes available, all data from the file should be flushed to the xDB.
The submit queue file stores serialized values as follows: first value - number of entities, second value - position of the next entity, which must be submitted to xDB, the next values contain serialized analytics data.
The submit queue is processed using this class: Sitecore.Analytics.Data.DataAccess.SubmitQueue.FileSubmitQueue
If you want to debug to see how is processed decompile the class and create your own class and replace in Sitecore.Analytics.Tracking.confing
<submitQueue>
<queue type="Sitecore.Analytics.Data.DataAccess.SubmitQueue.FileSubmitQueue, Sitecore.Analytics" singleInstance="true" />
</submitQueue>

User likes on django accumulation

I have a simple pinterest clone app built and have a basic activity stream setup.
The activity stream only records when a new image is created, when an image is liked, when a new user is created, or when a followed user follows another user.
What I would like to implement and do not know how is accumulation, for example if 2 or more user like a certain image, I would prefer the activity stream to say:
"User 1 and User 2 like image"
Can any one help me achieve this?
The Action models in django-activity-stream could be helpful.
For example, when an Actor performs an action, you could look up if there was recently a similar Verb and Target combination by a different Actor, and then replace that earlier instance with a new one that includes the most recent Actor.

cPanel User Filter email rules - using regex to filter/move emails "older than x days"

cPanel Version: Unsure
Issue
I want to create a filter/rule that will move messages over X days old.
Basically I send emails that are alerts for other tasks through outlook to a specific email on my phone, I need to be able to automatically have the emails move/archive after 2 days, then if possible a second rule to then delete after 21 days.
Using calendar is not an option as these events are triggered either through a calendar reminder or from another VBA source.
I had thought that using the following may work, but I don't know of the Regex string I would need.
Rule: Any Header / Matches Regex
Any advice, direction is appreciated. Thank you in advance.