- Timestamp:
- 01/14/11 16:16:55 (12 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ChangeLog
r513 r514 1 2.0.2 (2011-02-13) 2 * Use tempfile.mkstemp instead of tempfile.mktemp 3 Reported by: Dennis Stam (SARA) 4 Author: Bas van der Vlies 5 1 6 2.0.1 (2011-02-12) 2 7 * An email address can match multiple trac accounts, closes #218 -
trunk/debian/changelog
r509 r514 1 email2trac (2.0.2-1) stable; urgency=low 2 3 * see Changelog 4 5 -- bas van der Vlies <bas@sara.nl> Fri, 14 Jan 2011 16:04:21 +0100 6 7 email2trac (2.0.1-4) stable; urgency=low 8 9 * added info message for syslog of charset not found 10 11 -- bas van der Vlies <basv@sara.nl> Wed, 12 Jan 2011 15:32:16 +0100 12 1 13 email2trac (2.0.1-3) stable; urgency=low 2 14 -
trunk/email2trac.py.in
r509 r514 415 415 def debug_body(self, message_body, temporary_file=False): 416 416 if temporary_file: 417 body_file = tempfile.mktemp('.email2trac') 417 (fd, body_file) = tempfile.mkstemp('.email2trac') 418 fx = os.fdopen(fd, 'wb') 418 419 else: 419 420 body_file = os.path.join(self.parameters.tmpdir, 'body.txt') 421 fx = open(body_file, 'wb') 420 422 421 423 if self.parameters.dry_run: … … 424 426 425 427 print 'writing body to %s' %(body_file) 426 fx = open(body_file, 'wb')427 428 if not message_body: 428 429 message_body = '(None)' … … 490 491 491 492 if create_tempfile: 492 msg_file = tempfile.mktemp('.email2trac') 493 (fd, msg_file) = tempfile.mkstemp('.email2trac') 494 fx = os.fdopen(fd, 'wb') 493 495 else: 494 496 #msg_file = '/var/tmp/msg.txt' 495 497 msg_file = os.path.join(self.parameters.tmpdir, 'msg.txt') 498 fx = open(msg_file, 'wb') 496 499 497 500 if self.parameters.dry_run: … … 500 503 print 'saving email to %s' %(msg_file) 501 504 502 fx = open(msg_file, 'wb')503 505 fx.write('%s' % message) 504 506 fx.close() … … 537 539 temp = unicode(text, 'iso-8859-15') 538 540 except LookupError, detail: 539 #text = 'ERROR: Could not find charset: %s, please install' %format 541 msg = 'ERROR: Could not find charset: %s, please install' %format 542 sys.logger.error(msg) 540 543 #temp = unicode(text, 'iso-8859-15') 541 544 temp = message_str … … 614 617 parsed_data = None 615 618 if self.parameters.html2text_cmd: 616 tmp_file = tempfile.mktemp('email2trac.html') 619 (fd, tmp_file) = tempfile.mkstemp('email2trac.html') 620 f = os.fdopen(fd, 'w') 621 617 622 cmd = '%s %s' %(self.parameters.html2text_cmd, tmp_file) 618 623 self.logger.debug('\t html2text conversion %s'%(cmd)) … … 622 627 623 628 else: 624 f = open(tmp_file, "w+")625 629 f.write(data) 626 630 f.close() -
trunk/email2trac.spec
r506 r514 1 1 Summary: Utilities for converting emails to trac tickets 2 2 Name: email2trac 3 Version: 2.0. 13 Version: 2.0.2 4 4 Release: 1 5 5 License: GPL
Note: See TracChangeset
for help on using the changeset viewer.