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

Add icalendar 5.0 support and test against 5.0 and 6.x #160

Open
wants to merge 16 commits into
base: master
Choose a base branch
from

Conversation

DerDreschner
Copy link
Contributor

@DerDreschner DerDreschner commented Jan 19, 2025

Support for icalendar 5.0 seems to be still wanted by @eigenmannmartin. This needs a little workaround to make it possible, which was discussed in the review process of #159. For housekeeping reasons, I prefer separate pull requests for icalendar 5.0 support and test matrices for different Python versions.

This pull request therefore adds icalendar 5.0 support and implements the test matrix. I also improved the pipelines a little bit.

Fixes #147

Copy link

codecov bot commented Jan 19, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.44%. Comparing base (5dd30fe) to head (249e22b).
Report is 6 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #160      +/-   ##
==========================================
+ Coverage   91.88%   92.44%   +0.56%     
==========================================
  Files           4        4              
  Lines         382      384       +2     
  Branches       93       94       +1     
==========================================
+ Hits          351      355       +4     
+ Misses         14       12       -2     
  Partials       17       17              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@DerDreschner

This comment was marked as resolved.

@DerDreschner

This comment was marked as outdated.

@DerDreschner

This comment was marked as outdated.

@DerDreschner DerDreschner changed the title Add icalendar 5.0 support and test against 5.0/6.0/6.1 Add icalendar 5.0 support and test against 5.0 and 6.x Jan 24, 2025
@DerDreschner
Copy link
Contributor Author

DerDreschner commented Jan 24, 2025

The after_n_builds parameter can be changed with a local codecov.yml file in the repository. The codecov.notify.after_n_builds setting is being considered for pull request comments as well.

I set the setting with a local codecov.yml file now. That means that there's no need to change any settings on codecov itself. @eigenmannmartin

Copy link
Member

@eigenmannmartin eigenmannmartin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome work! I am not shure why the permission settings are required. otherwise, looks great. Thanks for the work!

@@ -5,30 +5,34 @@ on:
tags:
- '*'

permissions:
contents: read
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is this needed?

Copy link
Contributor Author

@DerDreschner DerDreschner Jan 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's recommended by the setup-python action to set it to read. According to the GitHub documentation, the default would be none, which means that the whole action has no read permission to the content of the repository. I know it works without it for now, but well, if they they say it may not work, I introduced it here to be sure.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good to know. thanks for pointing this out

python -m pip install --upgrade pip
pip install poetry==2.0.1
- name: "Install poetry"
uses: abatilo/actions-poetry@v3
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not a huge fan of extra deps in the build steps

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mhm, yeah, I understand. But it's more readable in my opinion and when you look at the code of the action, it doesn't do a lot different then the code before. Main difference is the encapsulation of poetry from the global python environment inside the docker container by using pipx instead of pip.

If you feel better about it, I can revert the changes. But I would keep the separation in two build steps (install poetry itself - install the project dependencies).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets do that, than we can merge and publish

pip install poetry==2.0.1
poetry install
- name: Test with pytest
poetry add icalendar~=${{ matrix.icalendar-version }}.0 --no-interaction
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome! :-)

Copy link
Member

@andrewgy8 andrewgy8 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work!

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

Successfully merging this pull request may close these issues.

Wrong pin
3 participants