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

Restore WebDAV functionality #772

Merged
merged 42 commits into from
Feb 5, 2020
Merged

Restore WebDAV functionality #772

merged 42 commits into from
Feb 5, 2020

Conversation

dataflake
Copy link
Member

Fixes #744

Reverts most of #696 as well as the the webdav part of 24d566b

Related to #649, #742 and to

This PR has been put together from several sources. The first was the move of the webdav package into ZServer (24d566b) and then the removal of all remaining support code in #696. I have left out anything that relates to FTP only, as that is an entirely separate protocol. Some inspiration was taken from https://github.com/datakurre/ZServer/tree/py3 by @datakurre.

With the webdav package back in Zope supporting the refreshed ZServer code by @datakurre should become easier as well.

@dataflake dataflake added this to the 5.0 milestone Jan 29, 2020
@dataflake dataflake requested review from thet and icemac January 29, 2020 02:48
@dataflake dataflake self-assigned this Jan 29, 2020
@dataflake dataflake added this to In progress in Zope 5.0 via automation Jan 29, 2020
Copy link
Member

@icemac icemac left a comment

Choose a reason for hiding this comment

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

Thank you for your effort to tackle this issue!

I did not look very deeply into the code (as it was mostly restoring pre-existing code.)
I did not try out the code as I do not use WebDAV anywhere. (Maybe I can look into it on Alpine City Sprint).

One thing makes me a bit sad: the drop in test coverage even though there are quite a few tests but they them to cover too little of the code. Maybe we have to write more tests when issues are reported.

src/ZPublisher/BaseRequest.py Show resolved Hide resolved
src/webdav/PropertySheets.py Outdated Show resolved Hide resolved
Zope 5.0 automation moved this from In progress to Reviewer approved Jan 29, 2020
@icemac
Copy link
Member

icemac commented Jan 29, 2020

Should we even backport this PR to Zope 4 to ease the transition to Zope 4 and 5?

@datakurre
Copy link

@pbauer What do you think, if WebDAV without ZServer would be backported for Zope 4, would there be "final" Plone 5.x release for Python 2 with WebDAV on WSGI?

@dataflake
Copy link
Member Author

I have no problem backporting it to Zope 4, no. Once it's done. There's still work to be done, like making the default object creation better (who needs DTML Documents anymore?), I need to look at the locking mechanism and its representation in the ZMI, and of course some real life testing.

@pbauer
Copy link
Member

pbauer commented Jan 30, 2020

I could also imaging re-adding webdav-support to a 5.2.x release if its not a breaking change. Semantically 5.3 release would be correct though but I fear that would raise expectation to have more features that we're probably not be able to live up to.

@dataflake dataflake marked this pull request as ready for review February 1, 2020 22:49
@dataflake
Copy link
Member Author

The WebDAV reintegration PR is now ready for review. I will leave this open for a few days if anyone wants to suggest corrections or improvements.

If you go to https://github.com/zopefoundation/Zope/tree/webdav/src/webdav and scroll down you will also see testing notes from tests with the "litmus" WebDAV test tool, including tests against the first implementation in 2007. The current code is a bit better since I took the time to continue diagnosis on some of the issues @mcdonc found back then.

@pbauer
Copy link
Member

pbauer commented Feb 3, 2020

I'd love to test this with Plone but we first have to make the branch for Plone 6 to run with the current state of Zope 5. We might find the time to do that at the Alpine City Sprint in Innsbruck next week. But please don't wait for us when it is ready merge!

@dataflake
Copy link
Member Author

As soon as it's merged I will backport the whole thing to the 4.x branch. 4.x needs a new release soon, anyway. I'll call that 4.2 then.

@icemac icemac self-requested a review February 4, 2020 07:26
@dataflake dataflake merged commit 12a4c88 into master Feb 5, 2020
Zope 5.0 automation moved this from Reviewer approved to Done Feb 5, 2020
@dataflake dataflake deleted the webdav branch February 5, 2020 02:10
dataflake added a commit that referenced this pull request Feb 5, 2020
* Move in the code from Zope.

Based on d1536a5.

* Move new Zope2.startup.config module into ZServer.

* Add explicit security declaration on webdav.Collection class.

* Move IFTPAccess from OFS.

* flake8

* Use `@implementer` class decorator.

* pep8

* Fix deprecations (#10)

* A released Zope is enough.
* Fix deprecation warnings occurring during a test run.
* Update to versions requested by buildout.cfg.
* Add coveralls.
* Add coverage config.

* - checkpoint checkin

* - checkpoint checkin

* - unit tests passing

* - satisfy isort

* - satisfy flake8

* - remove long-deprecated items

* - more cleanup

* - fixes with help from the Litmus Test (http://www.webdav.org/neon/litmus/)

* - setting Connection header is forbidden for WSGI

See https://www.python.org/dev/peps/pep-3333/#other-http-features

* Revert "Remove `Control_Panel/DavLocks`."

This reverts commit eec9a47.

* - lint fixes

* - fix up the old ZMI pages for locks and Null Resources

* - don't show lock icon for all path elements

* - remove faux implementation to make locking work

* - set ETags, so more Litmus tests pass

* - more fixes to improve Litmus coverage and real-life tests with cadaver

* - reinstate setting enable-ms-public-header

* - remove all references to FTP

* - add icons for the lock manager and the null resource

* - rename the testing information so it shows on GitHub

* - format for MarkDown

* - prevent numbers rendering as roman numerals

* - more Markdown fixing

* - last quoting fixes

* - add numerical test results

* - add change log entry

* - whitespace

Co-authored-by: Hanno Schlichting <hanno@hannosch.eu>
Co-authored-by: Michael Howitz <mh@gocept.com>
dataflake added a commit that referenced this pull request Feb 9, 2020
* Move in the code from Zope.

Based on d1536a5.

* Move new Zope2.startup.config module into ZServer.

* Add explicit security declaration on webdav.Collection class.

* Move IFTPAccess from OFS.

* flake8

* Use `@implementer` class decorator.

* pep8

* Fix deprecations (#10)

* A released Zope is enough.
* Fix deprecation warnings occurring during a test run.
* Update to versions requested by buildout.cfg.
* Add coveralls.
* Add coverage config.

* - checkpoint checkin

* - checkpoint checkin

* - unit tests passing

* - satisfy isort

* - satisfy flake8

* - remove long-deprecated items

* - more cleanup

* - fixes with help from the Litmus Test (http://www.webdav.org/neon/litmus/)

* - setting Connection header is forbidden for WSGI

See https://www.python.org/dev/peps/pep-3333/#other-http-features

* Revert "Remove `Control_Panel/DavLocks`."

This reverts commit eec9a47.

* - lint fixes

* - fix up the old ZMI pages for locks and Null Resources

* - don't show lock icon for all path elements

* - remove faux implementation to make locking work

* - set ETags, so more Litmus tests pass

* - more fixes to improve Litmus coverage and real-life tests with cadaver

* - reinstate setting enable-ms-public-header

* - remove all references to FTP

* - add icons for the lock manager and the null resource

* - rename the testing information so it shows on GitHub

* - format for MarkDown

* - prevent numbers rendering as roman numerals

* - more Markdown fixing

* - last quoting fixes

* - add numerical test results

* - add change log entry

* - whitespace

Co-authored-by: Hanno Schlichting <hanno@hannosch.eu>
Co-authored-by: Michael Howitz <mh@gocept.com>

Co-authored-by: Hanno Schlichting <hanno@hannosch.eu>
Co-authored-by: Michael Howitz <mh@gocept.com>
@dataflake
Copy link
Member Author

FYI, Zope 4.2 is now released and it contains the WebDAV support code.

@zopyx
Copy link
Member

zopyx commented Mar 4, 2020

How do you enable the WebDAV support in Zope 5.0a1? Setting webdav-source-port is enough or do you habe to make changes to the WSGI configuration?

@dataflake
Copy link
Member Author

@zopyx It would be sufficient to ask this question in one place and not place the identical question in three places. Please read the documentation for webdav-source-port at https://zope.readthedocs.io/en/latest/operation.html#zope-configuration-reference

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Zope 5.0
  
Done
Development

Successfully merging this pull request may close these issues.

Re-integrate WebDAV support
6 participants