• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

collective / icalendar / 18650027834
98%

Build:
DEFAULT BRANCH: main
Ran 20 Oct 2025 11:06AM UTC
Jobs 8
Files 127
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

20 Oct 2025 11:05AM UTC coverage: 97.855% (+0.02%) from 97.84%
18650027834

push

github

web-flow
Fix VALUE parameter handling for date/time properties (#915)

* Fix VALUE parameter handling for date/time properties

The problem: when you add a property with a datetime.date object, the library
wasn't setting VALUE=DATE in the output. This meant other calendar apps might
misinterpret the data.

What changed:
- Python date objects now automatically get VALUE=DATE
- Python time objects now automatically get VALUE=TIME
- The VALUE parameter is respected when parsing iCalendar data
- RDATE/EXDATE always use vDDDLists to properly handle lists

How it works:
Added a helper function that looks at the Python type and figures out what
VALUE parameter should be. The encoding path checks this and auto-sets the
parameter. The decoding path extracts VALUE and uses it to pick the right
parser.

This builds on earlier work by @thet (PR #331) and @stlaz (PR #196).

Fixes #349
Related to #187

* Update CHANGES.rst

Co-authored-by: Steve Piercy <web@stevepiercy.com>

* Update src/icalendar/cal/component.py

Co-authored-by: Steve Piercy <web@stevepiercy.com>

* Update src/icalendar/cal/component.py

Co-authored-by: Steve Piercy <web@stevepiercy.com>

* Update src/icalendar/cal/component.py

Co-authored-by: Steve Piercy <web@stevepiercy.com>

* Update src/icalendar/cal/component.py

Co-authored-by: Steve Piercy <web@stevepiercy.com>

* Update src/icalendar/prop/__init__.py

Co-authored-by: Steve Piercy <web@stevepiercy.com>

* Address Nicco's review: remove .lower() calls and add type hints

* Remove accidentally committed _build directory

* Fix: Keep .lower() where needed for value lookups

Nicco was right that .lower() isn't needed for CaselessDict keys, but we still need it for:
- value_param: it's a string value used for dict lookup, not a key
- name in tuple check: Python tuple membership isn't case-insensitive

* Remove .lower() calls entirely as Nicco suggested

CaselessDict handles case-insensitivity for all dict operations.
Use .upper() for tuple membership ... (continued)

946 of 975 branches covered (97.03%)

Branch coverage included in aggregate %.

156 of 158 new or added lines in 4 files covered. (98.73%)

8088 of 8257 relevant lines covered (97.95%)

7.79 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
2
97.82
-0.31% src/icalendar/cal/component.py
Jobs
ID Job ID Ran Files Coverage
1 run-nopytz - 18650027834.1 20 Oct 2025 11:06AM UTC 127
95.66
GitHub Action Run
2 run-py312 - 18650027834.2 20 Oct 2025 11:07AM UTC 127
97.63
GitHub Action Run
3 run-py38 - 18650027834.3 20 Oct 2025 11:06AM UTC 127
97.66
GitHub Action Run
4 run-py310 - 18650027834.4 20 Oct 2025 11:07AM UTC 127
97.67
GitHub Action Run
5 run-py313 - 18650027834.5 20 Oct 2025 11:06AM UTC 127
97.63
GitHub Action Run
6 run-py311 - 18650027834.6 20 Oct 2025 11:06AM UTC 127
97.63
GitHub Action Run
7 run-py39 - 18650027834.7 20 Oct 2025 11:07AM UTC 127
97.67
GitHub Action Run
8 run-pypy3 - 18650027834.8 20 Oct 2025 11:13AM UTC 127
97.67
GitHub Action Run
Source Files on build 18650027834
  • Tree
  • List 127
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #18650027834
  • 2d4bd68c on github
  • Prev Build on main (#18647458943)
  • Next Build on main (#18684319404)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc