Move to python3, pymilter is available for python3
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
#!/usr/bin/env python2
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
@@ -108,7 +106,7 @@ class QuarantineMilter(Milter.Base):
|
||||
self.recipients_quarantines = {}
|
||||
|
||||
# iterate email headers
|
||||
recipients_to_check = self.recipients[:]
|
||||
recipients_to_check = self.recipients.copy()
|
||||
for header in self.headers:
|
||||
self.logger.debug("{}: checking header against configured quarantines: {}".format(self.queueid, header))
|
||||
# iterate quarantines
|
||||
@@ -137,7 +135,7 @@ class QuarantineMilter(Milter.Base):
|
||||
whitelisted_recipients = {}
|
||||
|
||||
# iterate recipients
|
||||
for recipient in recipients_to_check[:]:
|
||||
for recipient in recipients_to_check.copy():
|
||||
|
||||
if recipient in whitelisted_recipients:
|
||||
# recipient is whitelisted in this quarantine
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python2
|
||||
#!/usr/bin/env python
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
#!/usr/bin/env python2
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
#!/usr/bin/env python2
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
#!/usr/bin/env python2
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python2
|
||||
#!/usr/bin/env python
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
#!/usr/bin/env python2
|
||||
#
|
||||
# PyQuarantine-Milter is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
|
||||
12
setup.py
12
setup.py
@@ -5,10 +5,10 @@ def read_file(fname):
|
||||
return f.read()
|
||||
|
||||
setup(name = "pyquarantine",
|
||||
version = "1.0.0",
|
||||
version = "0.0.1",
|
||||
author = "Thomas Oettli",
|
||||
author_email = "spacefreak86@gmx.ch",
|
||||
description = "A milter to handle multiple quarantines.",
|
||||
author_email = "spacefreak@noop.ch",
|
||||
description = "A pymilter based sendmail/postfix pre-queue filter.",
|
||||
license = "GPL 3",
|
||||
keywords = "quarantine milter",
|
||||
url = "https://github.com/spacefreak86/pyquarantine-milter",
|
||||
@@ -22,7 +22,7 @@ setup(name = "pyquarantine",
|
||||
"License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)",
|
||||
"Operating System :: OS Independent",
|
||||
"Programming Language :: Python",
|
||||
"Programming Language :: Python :: 2.7",
|
||||
"Programming Language :: Python :: 3",
|
||||
"Topic :: Communications :: Email :: Quarantine"
|
||||
],
|
||||
entry_points = {
|
||||
@@ -31,6 +31,6 @@ setup(name = "pyquarantine",
|
||||
"pyquarantine=pyquarantine.cli:main"
|
||||
]
|
||||
},
|
||||
install_requires = ["pymilter", "peewee"],
|
||||
python_requires = ">=2.7,<3"
|
||||
install_requires = ["pymilter", "beautifulsoup4", "peewee"],
|
||||
python_requires = ">=3"
|
||||
)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python2
|
||||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
import pyquarantine.cli
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python2
|
||||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
import pyquarantine.run
|
||||
|
||||
Reference in New Issue
Block a user