Opened 14 years ago

Last modified 14 years ago

#1258 defect closed fixed (fixed)

FTP log.err problem

Reported by: mkerrin Owned by:
Priority: highest Milestone:
Component: ftp Keywords:
Cc: Jean-Paul Calderone, itamarst, mkerrin Branch:
Author:

Description


Attachments (1)

ftp.diff (358 bytes) - added by mkerrin 14 years ago.

Download all attachments as: .zip

Change History (8)

Changed 14 years ago by mkerrin

Attachment: ftp.diff added

comment:1 Changed 14 years ago by mkerrin

Hi,

  I am trying to get Zope3 using the Twisted server, and I have one last
problem.

  There is a log.err(err) call in the FTP server which is causing one of my
tests to fail and it also causing a traceback to be printed whenever some one
tries to access some content they don't have permissions to.

  The attached patch removes this line and if aplied all my tests pass.

  Thanks for the great product

  Michael Kerrin

comment:2 Changed 14 years ago by itamarst

(I think having this as urgent is reasonable, as zope3 ought to be able to use 2.1).

comment:3 Changed 14 years ago by Jean-Paul Calderone

Branch up for review at
svn://cvs.twistedmatrix.com/svn/Twisted/branches/exarkun/ftp-error-reporting

The change is a bit more inclusive, since I don't want to just drop the error on
the floor.  IFTPShell has been changed slightly.  send() and receive() are gone,
replaced with openForReading and openForWriting.  Each of these returns an
object which implements either send or receive (with the same semantics as the
methods previously on IFTPShell).  They can also fail if permission is not
granted to the file.  The protocol code has been adjusted to use this new API
and handle errors from the two phases separately.  This lets usual errors, like
permission being denied, be handled appropriately and reported to the user
without requiring them to be logged on the server.  Unexpected errors are still
passed to log.err(), but none of these should be encountered during normal
operation.

comment:4 Changed 14 years ago by Jean-Paul Calderone

Resolved by r14772

comment:5 Changed 14 years ago by mkerrin

Thanks a million for this. I am just back from a Zope 3 sprint in Germany so I  
will try and port the Zope3 FTP implementation to the new code by tomorrow.  
  
Thanks again.

comment:6 Changed 14 years ago by mkerrin

I didn't mean to change the status of this issue - sorry

comment:7 Changed 8 years ago by <automation>

Owner: Jean-Paul Calderone deleted
Note: See TracTickets for help on using tickets.