Joao Bueno committed 9f94808

Updating setup, fixing typos

Comments (0)

Files changed (5)

 be used in any Python expression.
 Currently, the only public member in the
-project is the "paralell" decorator, which is used just as:
+project is the "parallel" decorator, which is used just as:
 def retr_url(url):
     return urllib.urlopen(url).read()
 # coding: utf-8
 # Author: João S. O. Bueno
-from _lelo import paralell
+from _lelo import parallel
     return True
-class MetaParalell(type):
+class MetaParallel(type):
     def __new__(metacls, name, bases, dct):
         # FIXME: check the data_model
         # and other Python documentation -
     of use if it is not complete
-LazyCallWrapper = MetaParalell("paralell", (CallWrapper,), {})
+LazyCallWrapper = MetaParallel("parallel", (CallWrapper,), {})
 class Wrapper(object):
-paralell = Wrapper
+parallel = Wrapper
 from setuptools import setup, find_packages
 import sys, os
-version = '0.0'
+version = '1.0rc1'
-      description="Utilities for easy paralellisation of tasks",
+      description="Utilities for easy parallelisation of tasks",
-      classifiers=[], # Get strings from
+      classifiers=[
+            "Development Status :: 4 - Beta",
+            "Environment :: No Input/Output (Daemon)",
+            "Intended Audience :: Developers",
+            "License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)",
+            "Operating System :: OS Independent",
+          ], # Get strings from
       keywords='python parallel highperformance multicore core thread multithread python2',
       author='Joao S. O. Bueno',
-      url='',
+      url='',
       packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
 import sys, os
 sys.path.insert(0, "..")
-from lelo import paralell
+from lelo import parallel
 import unittest
 class Tests(unittest.TestCase):
         self.assertEqual(result._value, 5)
     def test_lazy_class_factory(self):
-        from lelo._lelo import MetaParalell
-        X = MetaParalell("X", (object,), {})
+        from lelo._lelo import MetaParallel
+        X = MetaParallel("X", (object,), {})
         x = X()
         object.__setattr__(x, "_value", 10)
         self.assertEqual(x + 0, 10)
         object.__setattr__(x, "_value", {"y": 10})
         self.assertEqual(list(x.keys()), ["y"])
-    def test_paralell_function_creation(self):
+    def test_parallel_function_creation(self):
         from types import MethodType
-        @paralell
+        @parallel
         def soma(a, b):
             return a + b
         x = getattr(soma, "__call__")
         self.assert_(x.__class__, MethodType)
-    def test_paralell_execution(self):
-        @paralell
+    def test_parallel_execution(self):
+        @parallel
         def soma(a, b):
             return a + b
         result = soma(2,3)
         def retr_html(url):
             return urllib.urlopen(url).read()
-        fast = paralell(retr_html)
+        fast = parallel(retr_html)
         t0 = time.time()
         res_0 = fast(url)
         t0 = time.time() - t0
         #print "sync: %f, async: %f" % (t1, t0)
         self.assert_(t0 < t1)
-        self.assertEqual(len(res_0) // 10, len(res_1) // 10)
+        self.assertEqual(len(res_0) // 200, len(res_1) // 200)
 if __name__ == "__main__":
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.