# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django.contrib import admin
from patchwork.models import (
"""Utility to parse an mbox archive file."""
+from __future__ import absolute_import
+
import argparse
import logging
import mailbox
import django
-import parsemail
+from . import parsemail
VERBOSITY_LEVELS = {
'debug': logging.DEBUG,
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
import argparse
import codecs
import datetime
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import print_function
import sys
import subprocess
revs = commits(options, revspec)
for rev in revs:
- print rev
- print commit(options, rev)
+ print(rev)
+ print(commit(options, rev))
if __name__ == '__main__':
sys.exit(main(sys.argv))
-
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from patchwork.models import Person, State
from django.utils.safestring import mark_safe
from django.utils.html import escape
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
from django.contrib.auth.models import User
from django import forms
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
from django.core import paginator
from django.conf import settings
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+from __future__ import print_function
import hashlib
import re
(patch, comment) = parse_patch(content)
if options.print_hash and patch:
- print hash_patch(patch).hexdigest()
+ print(hash_patch(patch).hexdigest())
if options.print_patch and patch:
- print "Patch: ------\n" + patch
+ print("Patch: ------\n" + patch)
if options.print_comment and comment:
- print "Comment: ----\n" + comment
+ print("Comment: ----\n" + comment)
if __name__ == '__main__':
import sys
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django.template import RequestContext
from django.utils.html import escape
from django.contrib.sites.models import Site
http://www.revsys.com/blog/2014/nov/21/recommended-django-project-layout/
"""
+from __future__ import absolute_import
+
import django
-from base import *
+from .base import *
#
# Core settings
http://www.revsys.com/blog/2014/nov/21/recommended-django-project-layout/
"""
-from base import *
+from __future__ import absolute_import
+
+from .base import *
#
# Core settings
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django import template
from django.utils.html import escape
from django.utils.encoding import smart_str
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django import template
from django.utils.safestring import mark_safe
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django import template
from django.utils.html import escape
from django.utils.safestring import mark_safe
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django import template
from django.utils.html import escape
from django.utils.safestring import mark_safe
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
import unittest
import datetime
from django.test import TestCase
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
import unittest
import random
import datetime
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
import unittest
from django.test import TestCase
from django.test.client import Client
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
import itertools
import datetime
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
-from base import *
+from .base import *
from patchwork.utils import Order, get_patch_ids, bundle_actions, set_bundle
from patchwork.paginator import Paginator
from patchwork.forms import MultiplePatchForm
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
import json
from patchwork.models import Patch, Project, Person, EmailConfirmation
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from django.contrib.auth.decorators import login_required
from django.contrib.auth.models import User
from django.shortcuts import render_to_response, get_object_or_404
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
+
from patchwork.requestcontext import PatchworkRequestContext
from patchwork.models import EmailOptout, EmailConfirmation
from patchwork.forms import OptinoutRequestForm, EmailForm
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
from patchwork.models import Patch, Project, Bundle
from patchwork.forms import PatchForm, CreateBundleForm
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
from patchwork.models import Patch, Project
from django.shortcuts import render_to_response, get_object_or_404
# along with Patchwork; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+from __future__ import absolute_import
from django.contrib.auth.decorators import login_required
from patchwork.requestcontext import PatchworkRequestContext
# Patchwork XMLRPC interface
#
+from __future__ import absolute_import
+
from SimpleXMLRPCServer import SimpleXMLRPCDispatcher
from DocXMLRPCServer import XMLRPCDocGenerator
import base64