Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Fronleichnam" missing as official Holiday #252

Closed
pete1019 opened this issue Jun 3, 2021 · 20 comments · Fixed by #259
Closed

"Fronleichnam" missing as official Holiday #252

pete1019 opened this issue Jun 3, 2021 · 20 comments · Fixed by #259
Assignees
Labels
Milestone

Comments

@pete1019
Copy link

pete1019 commented Jun 3, 2021

Hi,

"Fronleichnam" is missing as official holiday today. Why is that?
Not listed in NRW nor Bayern. Don't know if others are missing, too.

Thanks a lot

@stelgenhof
Copy link
Member

Hi, Could you share some sample code that shows the holiday is missing? Thanks!

@pete1019
Copy link
Author

pete1019 commented Jun 3, 2021

Sure:

`
...
$official = new Yasumi\Filters\OfficialHolidaysFilter($ho->getIterator());
foreach ($official as $h) {
if (strval($d) === strval($h))
die('isholiday');
}
die("notholiday");
....
}

`

And this is the List for NRW:
2021-01-01: newYearsDay
2021-04-02: goodFriday
2021-04-05: easterMonday
2021-05-01: internationalWorkersDay
2021-05-13: ascensionDay
2021-05-24: pentecostMonday
2021-10-03: germanUnityDay
2021-12-25: christmasDay
2021-12-26: secondChristmasDay

And today is missing for "Hessen" and "Bayern" as well...maybe others, too.

Thanks!

@stelgenhof
Copy link
Member

Thanks for the example. I just found out that Corpus Christi is by default set to 'Other' which is likely the most sensible classification for any country that celebrates it. This is the case for Germany (and it's states) as well. Hence why these don't show up.

A reclassification for the respected states is then necessary in Yasumi.

@stelgenhof stelgenhof added the bug label Jun 3, 2021
@pete1019
Copy link
Author

pete1019 commented Jun 3, 2021

Thanks. When might a fix be available?

@github-actions
Copy link

github-actions bot commented Sep 2, 2021

Since this issue has not had any activity within the last 90 days, I have marked it as stale.
I will close it if no further activity occurs within the next 10 days.

@pete1019
Copy link
Author

pete1019 commented Sep 2, 2021

Hi, any news on this? Thanks a lot

Fronleichnam wird in folgenden Bundesländern als Feiertag begangen:

-Baden Württemberg
-Bayern
-Hessen
-Nordrhein-Westfalen
-Rheinland-Pfalz
-Saarland

@stelgenhof
Copy link
Member

I will look into it this week. Thanks for the reminder!

@stelgenhof stelgenhof added this to the v2.5.0 milestone Sep 2, 2021
@stelgenhof stelgenhof self-assigned this Sep 2, 2021
@stelgenhof
Copy link
Member

@pete1019 I have created a PR that will fix this issue. If you like to verify, please have a look at this PR.

@pete1019
Copy link
Author

pete1019 commented Sep 8, 2021

Thanks, how can i download and check?

@stelgenhof
Copy link
Member

You can checkout the fronleichnam-fix branch.

@pete1019
Copy link
Author

pete1019 commented Sep 8, 2021

ahh you mean this:
https://github.com/azuyalabs/yasumi/tree/fronleichnam-fix

okay i will test it and let you know.

@pete1019
Copy link
Author

pete1019 commented Sep 8, 2021

i tried downloading the code.zip and tried to replace the src folder but i got and internal server error.
I had it working with composer before.
How to get the fix "composer-friendly"?
PHP 7.2

Thanks

@stelgenhof
Copy link
Member

@pete1019 I don't think that would work indeed. If you want to go the Composer route, you would need to change the Yasumi version in your composer.json with the desired branch (see: https://getcomposer.org/doc/articles/aliases.md#why-aliases-)

You can also checkout the branch with Git and have your script point to that.

@pete1019
Copy link
Author

@stelgenhof thanks and how will i deal with this on 2.4.0?

  • Removed PHP 7.2 Support (PHP 7.2 is EOL)

I can not upgrade PHP 7.2 at this point.

Is your fix only available for 2.4.0 which does not have PHP 7.2 support anymore?
https://github.com/azuyalabs/yasumi/tree/fronleichnam-fix

THANKS!

@stelgenhof
Copy link
Member

@pete1019 It will be fixed in the upcoming 2.5.0 release. 2.4 and 2.5 have support for PHP7.3 or higher as these are the official supported PHP versions.

@pete1019
Copy link
Author

@stelgenhof so i am out of luck with PHP 7.2 for now? I need to upgrade to 7.3?
You used special PHP 7.3 functions or is it just coded that PHP 7.2 is not allowed to use with YASUMI anymore?
Thanks.

@stelgenhof
Copy link
Member

@pete1019 Don't know by heart but probably some specific 7.3 syntax indeed is used since 2.4.

@stelgenhof
Copy link
Member

@pete1019 Were you able to do some checks?

@pete1019
Copy link
Author

@stelgenhof unfortunately not since the PBX i am using it on still is on PHP 7.2. Hope at least PHP 7.3 in the next weeks / months.

@stelgenhof
Copy link
Member

@pete1019 I went ahead and merging your PR. I am aware you may not have time yet to check everything, however if we find some issues we can always fix them at any time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants