Menu

#53 mboxtrain.py doesn't find Maildir tmp/ directory properly

closed-fixed
nobody
None
5
2003-08-19
2003-04-15
No

The Maildir handler for mboxtrain.py tries to use a
tmp/ under
the directory passed to it. It should use a tmp/
directory at the same level (so given a ~/Maildir/cur,
it should use ~/Maildir/tmp).

Discussion

  • David M. Cooke

    David M. Cooke - 2003-04-15

    Fix for handling of tmp/ directory

     
  • David Ripton

    David Ripton - 2003-05-17

    Logged In: YES
    user_id=9425

    This is still broken as of latest CVS on 2003-05-17

    Example output from an mboxtrain cron job very similar to
    the one in HAMMIE.txt:

    Training ham (/home/dripton/Maildir/):
    Reading as Maildir
    1052838601.29078_0.ludo:2,RS
    1052472674.1616_0.ludo:2,RS
    1049307199.16131_1.dydimus,S=829:2,S
    1047587487.1367_2.hoggle:2,S
    1051558961.21629_2.willum:2,RS
    1053034631.15484_1.willum:2,S
    Traceback (most recent call last):
    File "/home/dripton/src/spambayes/mboxtrain.py", line 294,
    in ?
    main()
    File "/home/dripton/src/spambayes/mboxtrain.py", line 281,
    in main
    train(h, g, False, force, trainnew)
    File "/home/dripton/src/spambayes/mboxtrain.py", line 216,
    in train
    maildir_train(h, os.path.join(path, "cur"), is_spam, force)
    File "/home/dripton/src/spambayes/mboxtrain.py", line 113,
    in maildir_train
    f = file(tfn, "wb")
    IOError: [Errno 2] No such file or directory:
    '/home/dripton/Maildir/cur/tmp/1053163264.21320_6.vidar'

    The one-line patch already attached to this bug works for
    me. Please apply it to CVS.

     
  • Daniel Buchmann

    Daniel Buchmann - 2003-06-03

    Logged In: YES
    user_id=184577

    Hi, just wanted to confirm this bug as of CVS 2003-06-03.
    The patch attached by dmcooke fixes the bug for me too, so I
    agree with dripton, it would be nice if the patch could be
    applied.

    Thanks. :)

     
  • Tony Meyer

    Tony Meyer - 2003-08-19

    Logged In: YES
    user_id=552329

    Whoops. I checked in the fix for this some time ago.

     
  • Tony Meyer

    Tony Meyer - 2003-08-19
    • status: open --> closed-fixed
     

Log in to post a comment.

MongoDB Logo MongoDB