shift-org / shift-docs

Shift2Bikes: website and calendar for shift and pedalpalooza
https://shift2bikes.org
Other
22 stars 14 forks source link

calendar: create iCalendar feed for "all future event data" #116

Open fool opened 5 years ago

fool commented 5 years ago

Overview

We got so involved in remaking the web calendar that we forgot that most people would rather use their own calendar (usually google or apple calendars) :P. Supporting this standard should give us both: https://en.wikipedia.org/wiki/ICalendar

We have fixed the pedalpalooza ical feed in early June 2021, and just need to port this to a "general calendar" version now!

Related

Might be able to reuse some code from RSS implementation: https://github.com/shift-org/shift-docs/issues/61 or the legacy codebase that had this: https://github.com/Shift2Bikes/shiftcal/commit/b053a31d8177d89799a8f03c9d67060175c01fc5

Requested by:

Requested by community member Johnny. fool would like it too, and at pedalpalooza time it would be cool++;

sdobz commented 5 years ago

This fixes the single event export: https://github.com/shift-org/shift-docs/pull/130

The same code can probably be tweaked to export many

sdobz commented 5 years ago

Aaaaaand now it supports startdate and enddate https://localhost:4443/api/ics.php?startdate=2019-1-1&enddate=2019-3-1

Careful using this, it'll happily fill your entire calendar with many events

fool commented 5 years ago

that is cool and does work as you specified, but we're looking for the normal calendar feed that is more like an RSS feed that you "subscribe" to for updates. While this is fine for "get a snapshot of calendar" purposes - most people who want it want updates. Josh merged your PR but I'm leaving this issue open to get that "feed-style" calendar implemented too :)

fool commented 5 years ago

should make this mounted here: http://www.shift2bikes.org/cal/icalpp.php since that's where it used to live

But first let's try it at some secret URL to see if it works first...since putting ti there will just "hook up" to previous users' calendar setups so we want to make sure it's right. @carrythebanner might have had the prior one on his phone to be able to test duplicates...

fool commented 5 years ago

this code is written but not yet deployed or tested. Hopefully this week!

naknomum commented 5 years ago

looking forward to this. (just emailed, got response -- thanks @fool !) i can test if you wish.

arudwick commented 3 years ago

Is anyone actively working on this? I see this as being very important to growing the influence of the organization

I may try to dig in at some point but have no experience working on this project yet :)

carrythebanner commented 3 years ago

If I recall correctly, this is closer to being finished than the ticket might imply. @fool probably knows more, but I think this was more an infrastructure issue than a code one. (Our new-ish server needs a certain service or package to be running to support it?) I think we were very close to re-launching it, but I can't recall exactly what the remaining barrier is.

arudwick commented 3 years ago

one thing i am noticing is that these instructions don't work for current dates

https://localhost:4443/api/ics.php?startdate=2021-1-1&enddate=2021-6-1

this seems like it is the same as issue # 245- not sure how to merge https://github.com/shift-org/shift-docs/issues/245

fool commented 3 years ago

Hey folks,

I think we have this fixed, finally! The work is only done for pedalpalooza (so this feed cuts off on 31 Aug), but that will cover the next 3 months. Could you try this out and let me know if you have any feedback?

https://www.shift2bikes.org/cal/icalpp.php

Once this looks good we'll port to the more general "all events" mode!

fool commented 3 years ago

I got no feedback, so we're considering this to be working for pedalpalooza and I've edited the title to be more clear about what is still missing.

arudwick commented 3 years ago

I just tried it out - imported into google calendar. I think things look good. There are a couple duplicates but I don't think that is due to this software. Thank you!!!

runverzagt commented 2 years ago

I imported into Thunderbird and Google Calendar, it looks good and was really easy! Just a couple things I noticed:

I am also seeing duplicates, but it looks like multiple people creating the same event (for example, Thursday Night Ride). In Thunderbird, the name of the calendar shows up as "icalpp" which seems not useful. But in Google it shows up as "PedalpaloozaVERSION:2.0". Maybe Thunderbird is using the File name?

fool commented 2 years ago

good sleuthing. We can change the filename pretty easily, I'll try to work on it on weds and post back to see if you remove/re-add and it looks better!

On Mon, Apr 18, 2022 at 9:15 AM Bobby Unverzagt @.***> wrote:

I imported into Thunderbird and Google Calendar, it looks good and was really easy! Just a couple things I noticed:

I am also seeing duplicates, but it looks like multiple people creating the same event (for example, Thursday Night Ride). In Thunderbird, the name of the calendar shows up as "icalpp" which seems not useful. But in Google it shows up as "PedalpaloozaVERSION:2.0". Maybe Thunderbird is using the File name?

— Reply to this email directly, view it on GitHub https://github.com/shift-org/shift-docs/issues/116#issuecomment-1101534820, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABX5IE3QWOVTEMSKMSSK43VFWDC3ANCNFSM4G677COA . You are receiving this because you were mentioned.Message ID: @.***>

fool commented 2 years ago

Heya @runverzagt !

Mind testing an updated path for the pedalpalooza feed for us? I won't remove the old one (it's at the path it was at 4-5 years ago and I heard from more than one person that their calendar "picked it back up magically!" if they still/already had it configured there), but I made a new one you can test here: https://deploy-preview-419--shift-docs.netlify.app/cal/pedalpalooza-calendar.php . Let me know if it looks better to you in Thunderbird (none of the dev team have it installed), and I'll merge that into production for us.

Thanks in advance for your help!

runverzagt commented 2 years ago

Looks like that fixed it! It now shows up as "pedalpalooza-calendar"

runverzagt commented 2 years ago

One more thing I just notice: The iCal events appear to have a different description (usually less verbose) than on the website. I've never made an event, so I don't know if these are two separate fields, or if there is a technical reason for the difference. But it would be great to have the whole description in the iCal!

See photos for example.

Screenshot 2022-06-05 112442 Screenshot 2022-06-05 112457

runverzagt commented 2 years ago

One more screenshot, from google calendar. Shows the same as thunderbird. Screenshot 2022-06-05 112834

arudwick commented 2 years ago

I wasn't sure whether to create a new issue or not but I have been thinking it would be great if we had a link to the ride page so that people can find more details easily since the description field doesn't have everything

On Sun, Jun 5, 2022, 11:29 AM Bobby Unverzagt @.***> wrote:

One more screenshot, from google calendar. Shows the same as thunderbird. [image: Screenshot 2022-06-05 112834] https://user-images.githubusercontent.com/5334140/172065095-1b2c9d1b-1eb1-4bd6-ba55-d319c63051ba.png

— Reply to this email directly, view it on GitHub https://github.com/shift-org/shift-docs/issues/116#issuecomment-1146861614, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALW46B7ITPGORGGKS3OCW2DVNTWWXANCNFSM4G677COA . You are receiving this because you commented.Message ID: @.***>

runverzagt commented 2 years ago

Judging from what I've found (in screenshots above), there is a link to the ride page. It isn't displayed in google calendar but it is on Thunderbird.

arudwick commented 2 years ago

Ah. I've been using the google calendar flavor so this is affecting my personal view :(

On Wed, Jun 29, 2022 at 5:47 PM Bobby Unverzagt @.***> wrote:

Judging from what I've found (in screenshots above), there is a link to the ride page. It isn't displayed in google calendar but it is on Thunderbird.

— Reply to this email directly, view it on GitHub https://github.com/shift-org/shift-docs/issues/116#issuecomment-1170630920, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALW46B3KV5S6PSTJARDIRD3VRTVBZANCNFSM4G677COA . You are receiving this because you commented.Message ID: @.***>

-- Allan Rudwick (503) 703-3910

carrythebanner commented 2 years ago

Judging from what I've found (in screenshots above), there is a link to the ride page. It isn't displayed in google calendar but it is on Thunderbird.

The ride link is included as an "attachment" on each event, which apparently displays on some calendars but not others. Not sure if that was done for a specific reason when this was originally developed, but at any rate, we can definitely look into adding the link in the body of the event description.

One more thing I just notice: The iCal events appear to have a different description (usually less verbose) than on the website. I've never made an event, so I don't know if these are two separate fields, or if there is a technical reason for the difference. But it would be great to have the whole description in the iCal!

We use the print description for the event description in this feed. Some people specifically fill that out, but if not, it just gets filled automatically with the first 120 characters of the full description. We'll have to see if there are character limits in ICS that necessitated this choice (either now or yesteryear when this was first developed). Even if we have to keep the short (aka print) description, adding a link in the body to the full description would be an easy way to jump over to the full description.

carrythebanner commented 2 years ago

See also #339 for an issue specifically about beefing up event details in this feed.

arudwick commented 1 year ago

Is there an all-shift-events calendar.php ? I noticed that none of this is advertised on the site as well - it might makes sense to advertise this functionality at some point

ionous commented 2 months ago

we got another request for this today. the issues to figure out are:

fool commented 2 months ago

my thoughts:

On Fri, May 10, 2024 at 9:32 PM ionous @.***> wrote:

we got another request for this today. the issues to figure out are:

  • should this be a separate url than the pedalp subscription link
  • if so, at what url? and where do we tell people about it?
  • what window of events do we want to report ( i dont think we necessarily want to report all past events; but i suspect if we immediately stop reporting them they will simply look like they vanished from people's rides. )
  • do we want to brand the events feed differently? ( give one the name pedalp and the other simply "shift" )

— Reply to this email directly, view it on GitHub https://github.com/shift-org/shift-docs/issues/116#issuecomment-2105540068, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABX5IGVOEDUANG5RJM5PRLZBWNNZAVCNFSM4G677COKU5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TEMJQGU2TIMBQGY4A . You are receiving this because you were mentioned.Message ID: @.***>