gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [libextractor-python] branch master updated (be5b4a2 -> 62d


From: gnunet
Subject: [GNUnet-SVN] [libextractor-python] branch master updated (be5b4a2 -> 62d0aab)
Date: Fri, 01 Dec 2017 14:43:05 +0100

This is an automated email from the git hooks/post-receive script.

ng0 pushed a change to branch master
in repository libextractor-python.

    from be5b4a2  gplv3
     new 5bb7674  init tox.ini with some flake8 defaults.
     new 62d0aab  Start making the python bindings py2 and py3 compatible.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 extract.py | 6 ++++--
 tox.ini    | 4 ++++
 2 files changed, 8 insertions(+), 2 deletions(-)
 create mode 100644 tox.ini

diff --git a/extract.py b/extract.py
index d9b3b86..2521d07 100644
--- a/extract.py
+++ b/extract.py
@@ -3,6 +3,7 @@
 
      This file is part of libextractor.
      (C) 2002, 2003, 2004, 2005 Vidyut Samanta and Christian Grothoff
+     (C) 2017 ng0 <address@hidden>
 
      libextractor is free software; you can redistribute it and/or modify
      it under the terms of the GNU General Public License as published
@@ -22,6 +23,7 @@
 Little demo how to use the libextractor Python binding.
 
 """
+from __future__ import print_function
 import extractor
 import sys
 from ctypes import *
@@ -35,11 +37,11 @@ def print_k(xt, plugin, type, format, mime, data, datalen):
 # (in general, depending on the mime type and format, only
 # the first 'datalen' bytes in 'data' should be used).
     if (format == extractor.EXTRACTOR_METAFORMAT_UTF8):
-        print "%s - %s" % (xtract.keywordTypes()[type],  mstr.value)
+        print("%s - %s" % (xtract.keywordTypes()[type],  mstr.value))
     return 0
 
 
 for arg in sys.argv[1:]:
-    print "Keywords from %s:" % arg
+    print("Keywords from %s:" % arg)
     xtract.extract(print_k, None, arg)
 
diff --git a/tox.ini b/tox.ini
new file mode 100644
index 0000000..48c7d49
--- /dev/null
+++ b/tox.ini
@@ -0,0 +1,4 @@
+[flake8]
+# These are things the devs don't agree make the python code more readable
+max-line-length = 160
+exclude = .git
\ No newline at end of file

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]