[Zope-CMF] A bit of a glitch with FTP PUT

Tres Seaver tseaver@digicool.com
Mon, 21 May 2001 07:37:49 -0400


seb bacon wrote:
> 
> * Tres Seaver <tseaver@novacoxmail.com> [010519 17:17]:
> > Jonathan Corbet wrote:
> > > I can work around this, but, to me, a proper solution is non-obvious.  It
> > > would be nice if FTP uploads that create items didn't circumvent the
> > > workflow mechanism.  Something for somebody's list, maybe...
> >
> > Improving our FTP and WebDAV integration story is pretty high on
> > our list;  we'll look at that this week.
> 
> I've been struggling with the WebDAV, myself.  I mentioned last week
> that one problem is that CookieCrumbler does redirection when
> Unauthorized is raised, which breaks WebDAV.  FWIW, although it's not
> exactly a watertight solution, I've found the attached works with all
> the clients I've tested it on.  And I can't think of any other way
> round it, unfortunately.

The simpler workaround is to clear the "auto_login_page" property of
the CookieCrumbler;  this disables its "eager redirect" behavior.
I do want a better solution;  one possibility is to have the publisher
hack some additional state into the REQUEST if it arrives on the
"WebDAV source port".
 
> The next problem is that uploading Files fails.  I think it's because
> there's no fallback for default, globbed-style mimetypes in the
> _mime_type_registry hack in PortalFolder: for example, the
> NullResource PUT factory ends up trying to create an
> application/octet-stream file as a normal File object, and of course
> fails.  I fixed it with a cheesey hack, because I know you've got
> this in mind for a TTW, fully configurable solution.  Any idea when
> you might be looking at this - it'd be pretty useful - please :)

We plan to kill off the existing '_mime_type_registry' bit in favor
of a solution which extends / collaborates with the 'portal_types'
tool to hold this mapping.

Thanks for the feedback!  WebDAV and FTP fixes are probably the last
stuff on the radar for a 1.1;  I'm hoping to cut a beta by Friday.

Tres.
-- 
===============================================================
Tres Seaver                                tseaver@digicool.com
Digital Creations     "Zope Dealers"       http://www.zope.org