SUMMARY Calendar of the digital clock shows winter solstice even though astronomical events are disabled in the settings. STEPS TO REPRODUCE 1. Have the digital clock in your panel. 2. Right-click in the digital clock → Settings → Calendar → Uncheck Astronomical Events → OK 2. Left-click in the digital clock opens the calendar. 3. Choose December as month. OBSERVED RESULT The winter solstice is shown as an event on December, 21. EXPECTED RESULT The winter solstice is NOT shown as an event on December, 21. SOFTWARE/OS VERSIONS Operating System: Kubuntu 21.04 KDE Plasma Version: 5.21.4 KDE Frameworks Version: 5.80.0 Qt Version: 5.15.2 Kernel Version: 5.11.0-40-generic OS Type: 64-bit Graphics Platform: X11 Processors: 8 × Intel® Core™ i7-7700HQ CPU @ 2.80GHz Memory: 7.6 GiB of RAM Graphics Processor: Mesa Intel® HD Graphics 630 ADDITIONAL INFORMATION Unlike the winter solstice, the summer solstice is correctly no longer displayed.
If you do have the plugin enabled, does it show up twice on that day? That's what happens for me. This indicates that the same event is coming from multiple calendar plugins. Do you have any holiday plugins also enabled? If you turn those off, does the last occurrence of the event finally disappear?
> If you do have the plugin enabled, does it show up twice on that day? That's what happens for me. Indeed, if both (Astronomical events and Holidays) are enabled, I see it twice also. > Do you have any holiday plugins also enabled? I'm using ci_fr, but I've also tested with at_de, and it's the same problem. > If you turn those off, does the last occurrence of the event finally disappear? If both (Astronomical events and Holidays) are disabled, indeed the last occurrence of the event finally disappears.
I can reproduce with the en_us holiday package, so it seems to be a problem that's not unique to a single one. Moving to the kholidays framework.
To the Digital Clock people: The solstice and equinox "holidays" are added to the Holiday list unconditionally. the holiday class has a categoryList. look in that list for QLatin1String("seasonal") filter on that.
Can we remove them from the holidays lists? They aren't holidays...
*** Bug 446329 has been marked as a duplicate of this bug. ***
I searched and played around with kholiday. I found out, when I comment at function https://lxr.kde.org/source/frameworks/kholidays/src/parsers/holidayparserdriver.cpp#0049 > Holiday::List HolidayParserDriver::parseHolidays(const QDate &startDate, const QDate &endDate) following rows >// for (int year = startDate.year(); year < endDate.year(); ++year) { >// for (auto s : {AstroSeasons::JuneSolstice, AstroSeasons::DecemberSolstice, AstroSeasons::MarchEquinox, AstroSeasons::SeptemberEquinox}) { >// const auto dt = AstroSeasons::seasonDate(s, year); >// if (dt >= startDate && dt <= endDate) { >// Holiday season; >// season.d->mDayType = Holiday::Workday; >// season.d->mObservedDate = dt; >// season.d->mDuration = 1; >// season.d->mName = AstroSeasons::seasonName(s); >// season.d->mCategoryList.append(QLatin1String("seasonal")); >// m_resultList.append(season); >// } >// } >// } everything works as expected. The autotests are also working. But I am not experienced enough to see, what this is good for and what is the influence to other parts.
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kholidays/-/merge_requests/34
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kholidays/-/merge_requests/38
Git commit 58c51df658c04361e648adcee711d3ae28289a9c by Allen Winter, on behalf of Alois Spitzbart. Committed on 10/04/2022 at 15:26. Pushed by winterz into branch 'master'. New function for plasma to generate holidays without astro seasons This function creates just holidays from the holiday files. Astro seasons are not included, which are calculated. In Plasma can the astro seasons displayed two times. When this function is used, this can prevented. I did get a better name. Maybe someone has a better idea. Would be Plasma as suffix better than Only? This a follow up to https://invent.kde.org/frameworks/kholidays/-/merge_requests/34 M +2 -0 CMakeLists.txt M +6 -0 autotests/CMakeLists.txt M +31 -0 autotests/testholidayregion.cpp M +2 -0 autotests/testholidayregion.h M +4 -0 docs/Doxyfile.local M +8 -1 src/CMakeLists.txt M +9 -0 src/holidayregion.cpp M +44 -0 src/holidayregion.h M +7 -1 src/parsers/holidayparserdriver.cpp M +10 -0 src/parsers/holidayparserdriver_p.h https://invent.kde.org/frameworks/kholidays/commit/58c51df658c04361e648adcee711d3ae28289a9c