diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0190cb88..ec0ff317 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -23,25 +23,23 @@ jobs: - ["3.10", "py310"] - ["pypy-3.9", "pypy3"] - ["3.10", "docs"] - - ["3.10", "plone"] - - ["3.11.0-rc.1", "py311"] + - ["3.11", "py311"] runs-on: ubuntu-latest name: ${{ matrix.config[1] }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.config[0] }} - - name: Pip cache - uses: actions/cache@v2 - with: - path: ~/.cache/pip - key: ${{ runner.os }}-pip-${{ matrix.config[0] }}-${{ hashFiles('setup.*', 'tox.ini') }} - restore-keys: | - ${{ runner.os }}-pip-${{ matrix.config[0] }}- - ${{ runner.os }}-pip- + # for caching, see + # https://github.com/actions/setup-python/blob/main/docs/advanced-usage.md#caching-packages + cache: 'pip' + cache-dependency-path: | + setup.* + tox.ini + requirements*.txt - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/.readthedocs.yml b/.readthedocs.yml index 2cc431e5..572db76f 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -12,9 +12,12 @@ sphinx: # Optionally build your docs in additional formats such as PDF and ePub formats: all -# Optionally set the version of Python and requirements required to build your docs +build: + os: ubuntu-22.04 + tools: + python: "3.11" + python: - version: 3.7 install: - requirements: requirements_docs.txt - method: pip diff --git a/CHANGES.rst b/CHANGES.rst index c34cb9ff..df69ed8a 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -10,6 +10,10 @@ Minor changes: Ref: #550 Fixes: #526 [jacadzaca] +- Update build configuration to build readthedocs. #538 +- No longer run the ``plone.app.event`` tests. +- Move pip caching into Python setup action. +- Check that issue #165 can be closed. Breaking changes: diff --git a/docs/maintenance.rst b/docs/maintenance.rst index 4e792413..e81e72d1 100644 --- a/docs/maintenance.rst +++ b/docs/maintenance.rst @@ -107,7 +107,7 @@ However, only people with ``PyPI environment access for GitHub Actions`` can app 9. If the release is approved by a maintainer. It will be pushed to `PyPI`_. If that happens, notify the issues that were fixed about this release. -10. Copy this to the start of ``CHANGES.rst`` and create a new commit with this on the ``master`` branch:: +10. Copy this to the start of ``CHANGES.rst``:: 5.0.2 (unreleased) ------------------ @@ -127,7 +127,18 @@ However, only people with ``PyPI environment access for GitHub Actions`` can app Bug fixes: - ... + +11. Push the new CHANGELOG so it is used for future changes. + + .. code-block:: bash + + git checkout master + git pull + git add CHANGES.rst + git commit -m"Add new CHANGELOG section for future release + See https://icalendar.readthedocs.io/en/latest/maintenance.html#new-releases" + git push upstream master # could be origin or whatever reference Links ----- diff --git a/src/icalendar/tests/calendars/issue_165_missing_event.ics b/src/icalendar/tests/calendars/issue_165_missing_event.ics new file mode 100644 index 00000000..b9675cf0 --- /dev/null +++ b/src/icalendar/tests/calendars/issue_165_missing_event.ics @@ -0,0 +1,28 @@ +BEGIN:VCALENDAR +METHOD:REQUEST +PRODID:Microsoft CDO for Microsoft Exchange +VERSION:2.0 +BEGIN:VTIMEZONE +TZID:GMT +0100 (Standard) / GMT +0200 (Daylight) +BEGIN:STANDARD +DTSTART:16010101T030000 +TZOFFSETFROM:+0200 +TZOFFSETTO:+0100 +RRULE:FREQ=YEARLY;WKST=MO;INTERVAL=1;BYMONTH=10;BYDAY=-1SU +END:STANDARD +BEGIN:DAYLIGHT +DTSTART:16010101T020000 +TZOFFSETFROM:+0100 +TZOFFSETTO:+0200 +RRULE:FREQ=YEARLY;WKST=MO;INTERVAL=1;BYMONTH=3;BYDAY=-1SU +END:DAYLIGHT +END:VTIMEZONE +BEGIN:VEVENT +DTSTAMP:20150703T071009Z +DTSTART;TZID="GMT +0100 (Standard) / GMT +0200 (Daylight)":20150703T100000 +SUMMARY:Sprint 25 Daily Standup +DTEND;TZID="GMT +0100 (Standard) / GMT +0200 (Daylight)":20150703T103000 +RRULE:FREQ=DAILY;UNTIL=20150722T080000Z;INTERVAL=1;BYDAY=MO, TU, WE, TH, FR + ;WKST=SU +END:VEVENT +END:VCALENDAR diff --git a/src/icalendar/tests/test_issue_165_missing_event.py b/src/icalendar/tests/test_issue_165_missing_event.py new file mode 100644 index 00000000..4f927fb2 --- /dev/null +++ b/src/icalendar/tests/test_issue_165_missing_event.py @@ -0,0 +1,9 @@ +'''Issue #165 - Problem parsing a file with event recurring on weekdays + + https://github.com/collective/icalendar/issues/165 +''' +from icalendar import Calendar + +def test_issue_165_missing_event(calendars): + events = list(calendars.issue_165_missing_event.walk('VEVENT')) + assert len(events) == 1, "There was an event missing from the parsed events' list." diff --git a/tox.ini b/tox.ini index c6f4a3a3..de951113 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ # to run for a specific environment, use ``tox -e ENVNAME`` [tox] -envlist = py37,py38,py39,py310,pypy3,docs,plone +envlist = py37,py38,py39,py310,py311,pypy3,docs # Note: the 'docs' env creates a 'build' directory which may interfere in strange ways # with the other environments. You might see this when you run the tests in parallel. # See https://github.com/collective/icalendar/pull/359#issuecomment-1214150269 @@ -23,17 +23,3 @@ changedir = docs allowlist_externals = make commands = make html - -[testenv:plone] -usedevelop = False -install = False -python = 3.10 -commands_pre = -# Install Plone and explicitly the single package that uses icalendar, plus the test runner. - pip install Plone plone.app.event[test] zope.testrunner -c https://dist.plone.org/release/6.0-dev/constraints.txt -# Install the dev version of the package, mostly so we can safely point to the path with the tests. - pip install -e "git+https://github.com/plone/plone.app.event.git\#egg=plone.app.event" -# icalendar is pinned in the constraints, but we want the current dev version. - pip install -e {toxinidir} -commands = - zope-testrunner --test-path={envdir}/src/plone-app-event {posargs:-vc}