summaryrefslogtreecommitdiff
path: root/scripts
Commit message (Collapse)AuthorAgeFilesLines
* Port to the new way of handling messages. Also we don't send emailbwarsaw1999-12-162-36/+36
| | | | | when the alias is misconfigured. This will just naturally happen in the error logs.
* Must read stdin into a StringIO object so that its seekable, sincebwarsaw1999-12-141-1/+3
| | | | Message.Message requires this.
* Port to the new bounce handling architecture.bwarsaw1999-12-092-8/+38
|
* Convert message delivery to pipeline architecture by usingbwarsaw1999-11-241-74/+48
| | | | | | | | | | | | | | | | | | | HandlerAPI.DeliverToUser() for fast track delivery of the welcome messages. Stick most code in main() Use LogStdErr Remove the fromusenet cruft -- since Usenet messages are gated to the newsgroup without going through the post script now, this is all unnecessary. Move the sending of postheld.txt to the Hold.py pipeline module, where it really belongs. Plus it won't work here because those exceptions aren't percolated up to the post script. MMLoopingPost exceptions still make it through and are handled here (although I suspect this should go into one of the handlers too).
* Convert message delivery to pipeline architecture by usingbwarsaw1999-11-242-32/+40
| | | | | | | | | HandlerAPI.DeliverToUser() for fast track delivery of the welcome messages. Stick everything in a main(). Simplify error reporting by using Mailman.Logging.Utils.LogStdErr
* Use convenience StringIO modulebwarsaw1999-11-101-5/+1
|
* Several changes to use the new Message objects and interface tobwarsaw1999-11-101-6/+13
| | | | | | | | | | | MailList.Post(), specifically: Message object ctor takes a file-like object, so use StringIO when the data is coming from a string. MailList.Post() no longer takes an approved argument. Setting the `fromusenet' attribute on the message object is enough to let the system know where the message is from.
* Use the new Mailman.Message.Message objects for the incoming messagebwarsaw1999-11-103-3/+3
|
* eradicate "maillist" as a nounbwarsaw1999-05-052-2/+2
|
* current_list => mlistbwarsaw1999-05-032-16/+12
| | | | comment clarification
* Post(): New policy for message loops (e.g. messages that show up atbwarsaw1999-04-161-14/+23
| | | | | | | | | | the mailing list that have a matching X-BeenThere header). Instead of holding such messages for approval, an MMLoopingPost error is raised. This is caught by the post CGI script, which logs this occurance and sends a notice (containing the original message) to the list admin. This way, the admin knows there's a problem and can track the loop down, but isn't so inconvenienced to go the the Web page just to discard the message (the usual disposition).
* tmp_prevent_gate attribute on the MailList objects is gone!bwarsaw1999-03-061-4/+12
| | | | | | | Stick a `fromusenet' attribute on the msg object, value taken from whether there is a magical second argument to the post script (only happens from GatewayManager). Also post message with approved flag set to fromusenet, so message originating on Usenet are pre-approved.
* VERSION is no longer set in configure because it's too hard tobwarsaw1999-01-151-2/+0
| | | | | | | | | | | | propagate version string changes to the public (you have to autoreconf, then reconfigure and reinstall). Now, VERSION is set directory in Defaults.py.in and the Release.py script updates that file directly. Now we just need to run ./config.status and do a re-install. I hope this will make things easier. I'm also bumping the version to 1.0b8, so I can do a release tomorrow.
* Changes to workaround some bogus clients which either don't include abwarsaw1999-01-081-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | content-type header, or include a bogus one. cgi.py FieldStorage.__init__(): if there is no content-type header, use text/plain for inner parts, but application/x-www-form-urlencoded for outer parts. Honor any existing content-type header. Lower down, if the content-type header is something we don't understand, default to text/plain for inner parts, but application/x-www-form-urlencoded for outer parts. This patch will be proposed for Python 1.5.2 driver run_main(): Play some games to get Mailman's special cgi.py module. We import it from Mailman.pythonlib.cgi, but then we jam this module into sys.modules['cgi'] so all those imports in all those Mailman.Cgi scripts get our special one (without having to hack all those scripts!)
* print_traceback(): A few changes to get the Mailman version numberbwarsaw1999-01-071-2/+10
| | | | into both the error log and the HTML page.
* move the import of Mailman.Utils.reraise into the debugging-open()bwarsaw1998-12-101-13/+13
| | | | | | definition -- the only place it's used. Also, comment out the whole def and __builtin__ hack. This debugging stuff probably shouldn't go into the release (although its use should be documented).
* Post last-minute bug - unexercised 'import mm_cfg' finally wasklm1998-11-072-2/+2
| | | | exercised - doesn't work. 'from Mailman import mm_cfg'.
* open(): in the debugging version, use Mailman.Utils.reraise() tobwarsaw1998-11-031-4/+3
| | | | portably re-raise the exception.
* make finishbwarsaw1998-10-201-0/+2
|
* Added DeliverToOwner to Deliverer class in Deliverer.py that passescotton1998-10-012-2/+4
| | | | | | | | | | a message to the -admin address to the owners untouched and with the sender of the original message Added a GetEnvelopeSender method to Message.py that attempts to find the envelope sender from a messages's unix from line for use by DeliverToOwner changed the mailowner script to use DeliverToOwner method instead of the DeliverToList method scott
* Use Util.maketext() and move post held message intobwarsaw1998-08-291-16/+8
| | | | templates/postheld.txt
* SendTextToUser() no longer takes a raw argumentbwarsaw1998-08-291-2/+1
|
* Changing policy about when notifications are sent for posts held forklm1998-08-131-6/+2
| | | | | | | | | | | | | | | | | approval - notifications are now sent even for suspected spam. I was experimenting with avoiding alerting spammers to spam filtering, but i've come to realize that: - Not notifying prevents non-spammers from getting any feedback when they inadvertantly trip a spam sensitivity, and - It's probably best to blast stuff back at spammers. In the common case that the return addresses are useless, no harm, and if the return addrs are good, then the more people using the spam protection, the more spam the spammer gets in response. The moral is, forthrightness is the best policy. Even if it does expose our measures and up the ante in the spam war, security via obscurity is a poor, and often misguided, approach.
* What about this one?bwarsaw1998-08-041-1/+1
|
* Sighbwarsaw1998-08-041-1/+1
|
* Another trivial rsync related changebwarsaw1998-08-041-1/+1
|
* One more timebwarsaw1998-08-031-3/+4
|
* Guess again :-)bwarsaw1998-08-031-2/+2
|
* Contrived change (to test rsync'ing)bwarsaw1998-08-031-1/+1
|
* open(): put filename on the e object as an attribute to mimic the waybwarsaw1998-08-031-0/+1
| | | | Python 1.5.2 will do it (for debugging)
* Using new, tidy mechanism for getting putting a StampedLogger onklm1998-08-031-7/+2
| | | | stderr. (I expect we should do this for all the scripts.)
* Removed obsolete import of StampedLogger.klm1998-08-032-2/+0
|
* Very substantially rewritten. The old driver script let too manybwarsaw1998-07-311-60/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | uncaught exceptions through to the top level. Uncommented out the open() definition. I think this is very helpful during the beta debugging phase. We'll comment this out for 1.0 release (it also won't be necessary in Python 1.5.2, but nobody has that yet!) Exception printing has been changed so that the MultiLogger is no longer necessary. Removes one more potential crash, but also rationalizes print_exception() and print_environment(). There's always exactly two places information goes: 1. To a plain text log file. This could be sys.__stderr__ if no explicit log file is given -- e.g. the Web server's log file. 2. To an HTML sink. This will always be sys.stdout (since we use the `print' statement), and will generally always be connected to the input of the Web browser. Log file printing happens first, just in case (it's better that the server knows what's happening), but we always try to print both. `Main' has been rewritten also. We now do not catch any problems with import sys. If sys can't be imported, then the Python installation is royally screwed -- even `print' won't work! Better to just let the catastrophy percolate up to the Web browser. Even so this should almost never happen. Poke __stderr__ and __stdout__ into the sys module if they aren't already there. GvR says this is a 1.5.1 feature, but we can make it work well enough for older versions of Python, and it's convenient. Give one final shot at printing the traceback and environment if the exception percolates all the way up out of run_main(). This time, just print them to stderr (usually meaning the Web server's error log). Should this fail too, do whatever we can not to generate an end-user visible server error.
* Not sure why this was missing...bwarsaw1998-07-311-0/+1
|
* run_main(): initialize logger and multi to sys.stderr. This is inbwarsaw1998-07-291-0/+5
| | | | | | | case anything breaks between the start of this function and the creation of the real objects, otherwise the calls in the except branch will fail, kicking us back to a low-level exception. using sys.stderr isn't great, but it's better than nothing.
* Use simplified LogStdErr() call to enable error logging from thisklm1998-07-232-12/+4
| | | | module all the time.
* Added a useful debugging hack (commented out).bwarsaw1998-07-221-0/+21
|
* Don't need to check whether the list is locked before doing the unlockklm1998-07-171-2/+1
| | | | - new version of Unlock takes care of that.
* Check for existing lock before unlocking.klm1998-07-151-2/+2
| | | | | | | | | | | | | | | | | QUESTION: The MailList.Unlock() method currently raises two different AttributeErrors when the list is not currently locked (depending on whether or not the lock was previously created). This certainly seems like the wrong exception. We could make .Unlock() check for the lock and return a better exception, or we could have it just return if the list is not locked. I'm inclined towards the latter, but it changes the character of the list locking interface a wee bit. I think it ought to be changed, one way or the other. John, what's your inclination? Ken
* StampedLogger now comes out of the Mailman.Logging.StampedLoggerbwarsaw1998-07-065-13/+15
| | | | | module (we should really create a mail driver similar to the CGI driver).
* Use the new Mailman.Logging package to provide better logging onbwarsaw1998-07-021-20/+23
| | | | | | | | errors. Now all tracebacks get sent to the user as HTML *and* logged to logs/error, although the format of the output is slightly different (not HTML in the latter case). Some rearranging of code, simplification, etc.
* Packagizedbwarsaw1998-06-196-56/+71
|
* New CGI driver script that attempts to import the real script from thebwarsaw1998-06-191-0/+147
| | | | | | | | | Mailman.Cgi package. Be as paranoid as possible about catching exceptions and reporting them as HTML (which has saved my butt numerous times already :-). See the comments in the file for things that can still cause Server errors.
* MAILDIR => SCRIPTSDIRbwarsaw1998-06-191-3/+3
|
* Add Unlock() calls where appropriate, and add lock = 0 to MailListviega1998-06-131-3/+1
| | | | constructor actuals when the list doesn't need to be locked.
* Modified post to take a second optional argument. If the second argumentviega1998-05-311-2/+7
| | | | | | | | is present, post realizes that it was called by the News->Mail gateway, and tells the mailing list not to Mail->News gateway anything. Actually, thinking about it, it is probably better to set a field in each message object saying "Don't send me to news!". I'll probably adjust that after I get to test the code.
* 1. Use the standard Python invocation #! line to get the interpreterbwarsaw1998-05-261-9/+8
| | | | | | | | | | | | | | | | | | | | | | | | from $PATH 2. Do no direct sys.path munging in this file. Import the `paths' module, which is created during the configure process, and which performs all necessary path munging (and exports some useful variables too). 3. Remove RCS crud Also: Removed all hardcoded absolute paths. Instead, calculate paths using paths.prefix as the base. Change ''' TQS to """ so as not to confuse font-lock. !!!! When calling SendTextToUser(), set the new optional argument raw=1 so that the text body will not be wrapped/filled. The checkin that implements wrapping and filling has not yet been made. Note that it would be nice if just the templated text could be wrapped/filled and the err_msg left alone, but that's currently too hard to separate.
* 1. Use the standard Python invocation #! line to get the interpreterbwarsaw1998-05-264-22/+12
| | | | | | | | | | | from $PATH 2. Do no direct sys.path munging in this file. Import the `paths' module, which is created during the configure process, and which performs all necessary path munging (and exports some useful variables too). 3. Remove RCS crud
* 1. Use the standard Python invocation #! line to get the interpreterbwarsaw1998-05-261-5/+7
| | | | | | | | | | | | | | from $PATH 2. Do no direct sys.path munging in this file. Import the `paths' module, which is created during the configure process, and which performs all necessary path munging (and exports some useful variables too). 3. Remove RCS crud Also, calculate path to majordomo.answer.txt file using paths.prefix as the path base.
* Autoconf template for this directory's Makefile.bwarsaw1998-05-261-0/+69
|