cubehouse / themeparks

Unofficial API for accessing ride wait times and schedules for Disneyland, Disney World, Universal Studios, and many more parks
MIT License
536 stars 126 forks source link

Incorrect Efteling opening hours #297

Closed HookDonn closed 3 years ago

HookDonn commented 4 years ago

Park Efteling

Context

Describe the bug Efteling's opening hours are not good. It is indicated 00:00 and 00:00 whereas with the official API of the park we recover the good schedules.

Output "Times":{"date":"2020-06-19","openingTime":"2020-06-19T00:00:00+02:00","closingTime":"2020-06-19T00:00:00+02:00","type":"Operating"}

And with official API (https://api.efteling.com/app/wis?language=en) :

  "OpeningHours": {
    "Date": "2020-06-19T00:00:00",
    "BusyIndication": "gezelligebedrijvigheid",
    "HourFrom": "2020-06-19T10:00:00",
    "HourTo": "2020-06-19T18:00:00"
  },
LouisForaux commented 4 years ago

It seems the Efteling website API for opening hours block some connexions.

For the example : https://www.efteling.com/service/cached/getpoiinfo/en/[year number]/[month number (2 digits)] return a 500 error for the moment.

HookDonn commented 4 years ago

Hum strange, for my part, this URL "https://www.efteling.com/service/cached/getpoiinfo/en/2020/06" works :/ Img : https://puu.sh/FYakR/97afb82678.png

LouisForaux commented 4 years ago

Sometimes it's working, after a 500 error...

It's really random

timyboy12345 commented 4 years ago

The problem is that the Efteling currently has multiple opening times per day (09:00/10:00-18:00 and from 19:00-23:00). This was added recently due to the Covid-19 pandemic. The API returns a different format of opening times, where there is a OpeningHours object in each day describing the different opening hours each day.

Currently, I believe, openinghours are also cached on a by-day basis. Meaning that it's impossible to cache multiple opening times for one day. This means that Themeparks can not return the correct opening times because it's only designed to return one time per day.

The current format for opening hours is:

{
   "OpeningHours":[
      {
         "Date":"2020-08-01",
         "OpeningHours":[
            {
               "Close":"18:00",
               "Open":"09:00"
            },
            {
               "Close":"23:00",
               "Open":"19:00"
            }
         ],
         "Crowded":1
      },
      {
         "Date":"2020-08-02",
         "OpeningHours":[
            {
               "Close":"18:00",
               "Open":"09:00"
            },
            {
               "Close":"23:00",
               "Open":"19:00"
            }
         ],
         "Crowded":1
      },
      ...
   ],
   "Maintenance":[

   ],
   ...
}
HookDonn commented 4 years ago

Efteling announced this: During June, Efteling is open, exclusively, to Annual Pass holders every Friday and Saturday evening from 19.00 to 23.00.

Which explains the different hours. We are not obliged to take this into account and thus keep only the opening hours to the public.

migo315 commented 4 years ago

Which explains the different hours. We are not obliged to take this into account and thus keep only the opening hours to the public.

This is correct for June as gift for the annual pass holders. But from July the times between 19:00 to 23:00 are open to everyone. You can buy a ticket for 09:00 to 18:00 or buy a ticket for 19:00 to 23:00.

cubehouse commented 4 years ago

Oh fun, never though we'd get theme parks returning multiple opening hours for guests like this (outside of ticketed events).

Might be sane to just return the park as closed, but return the two time slots as "special" times for now (they are sort-of "special times" in that you need to book ahead of time).

timyboy12345 commented 3 years ago

The Efteling just changed their opening times again. Since the attendance level was lower as anticipated they will once again just have one opening time a day. Hopefully this will fix the issue.

Maybe this could be something to put waaaaaaay back on the backburner. Since this could theoretically happen again, in the Efteling or somewhere else.

Source (Dutch): https://www.looopings.nl/weblog/14861/Efteling-stopt-met-aparte-zomeravonden-openingstijden-weer-aangepast.html

mattheuten commented 3 years ago

Hey @cubehouse, I am still experiencing this issue. Would you mind having a look? We'd like to use your API even more for a project.

cubehouse commented 3 years ago

I've pushed an update so that Efteling starts using the WIP 6.x setup, hopefully this resolves this issue for people. Let me know how it works for you.