Rev 65: Change the branding from 'memory_dump' to 'meliae'. in http://bazaar.launchpad.net/~jameinel/meliae/trunk

John Arbash Meinel john at arbash-meinel.com
Tue Sep 8 18:19:29 BST 2009


At http://bazaar.launchpad.net/~jameinel/meliae/trunk

------------------------------------------------------------
revno: 65
revision-id: john at arbash-meinel.com-20090908171916-ekr6d1c8gb0e0eih
parent: john at arbash-meinel.com-20090908171355-f8k1w7qcgd0ap1yo
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: trunk
timestamp: Tue 2009-09-08 12:19:16 -0500
message:
  Change the branding from 'memory_dump' to 'meliae'.
  While at it, notice that python2.6 has slightly larger Dicts (109 words vs 106 words).
  So update some of the tests for this discrepancy.
-------------- next part --------------
=== modified file '.bzrignore'
--- a/.bzrignore	2009-04-03 20:41:31 +0000
+++ b/.bzrignore	2009-09-08 17:19:16 +0000
@@ -1,4 +1,4 @@
 ./build
-./memory_dump/_intset.c
-./memory_dump/_loader.c
-./memory_dump/_scanner.c
+./meliae/_intset.c
+./meliae/_loader.c
+./meliae/_scanner.c

=== renamed directory 'memory_dump' => 'meliae'
=== modified file 'meliae/loader.py'
--- a/memory_dump/loader.py	2009-09-08 17:06:14 +0000
+++ b/meliae/loader.py	2009-09-08 17:19:16 +0000
@@ -30,7 +30,7 @@
 except ImportError:
     simplejson = None
 
-from memory_dump import (
+from meliae import (
     _intset,
     _loader,
     )

=== modified file 'meliae/scanner.py'
--- a/memory_dump/scanner.py	2009-09-08 17:06:14 +0000
+++ b/meliae/scanner.py	2009-09-08 17:19:16 +0000
@@ -19,7 +19,7 @@
 import gc
 import types
 
-from memory_dump import (
+from meliae import (
     _intset,
     _scanner,
     )

=== modified file 'meliae/tests/test__intset.py'
--- a/memory_dump/tests/test__intset.py	2009-09-08 17:13:55 +0000
+++ b/meliae/tests/test__intset.py	2009-09-08 17:19:16 +0000
@@ -16,7 +16,7 @@
 
 """Test the Set of Integers object."""
 
-from memory_dump import (
+from meliae import (
     _intset,
     tests,
     )

=== modified file 'meliae/tests/test__loader.py'
--- a/memory_dump/tests/test__loader.py	2009-09-08 17:13:55 +0000
+++ b/meliae/tests/test__loader.py	2009-09-08 17:19:16 +0000
@@ -16,7 +16,7 @@
 
 """Pyrex extension for tracking loaded objects"""
 
-from memory_dump import (
+from meliae import (
     _loader,
     tests,
     )

=== modified file 'meliae/tests/test__scanner.py'
--- a/memory_dump/tests/test__scanner.py	2009-09-08 17:13:55 +0000
+++ b/meliae/tests/test__scanner.py	2009-09-08 17:19:16 +0000
@@ -17,10 +17,11 @@
 """Tests for the object scanner."""
 
 import gc
+import sys
 import tempfile
 import types
 
-from memory_dump import (
+from meliae import (
     _scanner,
     tests,
     )
@@ -101,14 +102,20 @@
         self.assertSizeOf(31+512*3, dict.fromkeys(range(100)))
 
     def test_basic_types(self):
-        self.assertSizeOf(106, dict)
-        self.assertSizeOf(106, set)
-        self.assertSizeOf(106, tuple)
+        type_size = 106
+        if sys.version_info[:2] >= (2, 6):
+            type_size = 109
+        self.assertSizeOf(type_size, dict)
+        self.assertSizeOf(type_size, set)
+        self.assertSizeOf(type_size, tuple)
 
     def test_user_type(self):
         class Foo(object):
             pass
-        self.assertSizeOf(106, Foo)
+        if sys.version_info[:2] >= (2, 6):
+            self.assertSizeOf(109, Foo)
+        else:
+            self.assertSizeOf(106, Foo)
 
     def test_simple_object(self):
         obj = object()
@@ -313,7 +320,7 @@
         m = _scanner
         self.assertDumpText(
             '{"address": %d, "type": "module", "size": %d'
-            ', "name": "memory_dump._scanner", "refs": [%d]}\n'
+            ', "name": "meliae._scanner", "refs": [%d]}\n'
             % (id(m), _scanner.size_of(m), id(m.__dict__)), m)
 
 
@@ -321,7 +328,7 @@
     """dump_object_info should give the same result at py_dump_object_info"""
 
     def assertDumpInfo(self, obj, nodump=None):
-        t = tempfile.TemporaryFile(prefix='memory_dump-')
+        t = tempfile.TemporaryFile(prefix='meliae-')
         # On some platforms TemporaryFile returns a wrapper object with 'file'
         # being the real object, on others, the returned object *is* the real
         # file object

=== modified file 'meliae/tests/test_loader.py'
--- a/memory_dump/tests/test_loader.py	2009-09-08 17:13:55 +0000
+++ b/meliae/tests/test_loader.py	2009-09-08 17:19:16 +0000
@@ -19,7 +19,7 @@
 import sys
 import tempfile
 
-from memory_dump import (
+from meliae import (
     _loader,
     loader,
     scanner,
@@ -51,7 +51,7 @@
 
     def test_load_smoketest(self):
         test_dict = {1:2, None:'a string'}
-        t = tempfile.TemporaryFile(prefix='memory_dump-')
+        t = tempfile.TemporaryFile(prefix='meliae-')
         # On some platforms TemporaryFile returns a wrapper object with 'file'
         # being the real object, on others, the returned object *is* the real
         # file object

=== modified file 'meliae/tests/test_scanner.py'
--- a/memory_dump/tests/test_scanner.py	2009-09-08 17:13:55 +0000
+++ b/meliae/tests/test_scanner.py	2009-09-08 17:19:16 +0000
@@ -18,17 +18,17 @@
 
 import tempfile
 
-from memory_dump import (
+from meliae import (
     scanner,
     tests,
     )
-from memory_dump.tests import test__scanner
+from meliae.tests import test__scanner
 
 
 class TestDumpAllReferenced(tests.TestCase):
 
     def assertDumpAllReferenced(self, ref_objs, obj):
-        t = tempfile.TemporaryFile(prefix='memory_dump-')
+        t = tempfile.TemporaryFile(prefix='meliae-')
         # On some platforms TemporaryFile returns a wrapper object with 'file'
         # being the real object, on others, the returned object *is* the real
         # file object

=== modified file 'run_tests.py'
--- a/run_tests.py	2009-09-08 17:06:14 +0000
+++ b/run_tests.py	2009-09-08 17:19:16 +0000
@@ -27,8 +27,8 @@
                  help='run verbose tests')
 
     (opts, args) = p.parse_args(args)
-    import memory_dump.tests
-    return not memory_dump.tests.run_suite(verbose=opts.verbose)
+    import meliae.tests
+    return not meliae.tests.run_suite(verbose=opts.verbose)
 
 if __name__ == '__main__':
     sys.exit(main(sys.argv[1:]))

=== modified file 'setup.py'
--- a/setup.py	2009-09-08 17:06:14 +0000
+++ b/setup.py	2009-09-08 17:19:16 +0000
@@ -18,13 +18,14 @@
 def config():
     ext = []
     kwargs = {
-        "name": "memory_dump",
+        "name": "meliae",
         "version": "0.1.1",
         "description": "Dump Memory Content to disk for Python Programs",
         "author": "John Arbash Meinel",
         "author_email": "john.meinel at canonical.com",
-        "url": "https://launchpad.net/pymemorydump",
-        "packages": ["memory_dump"],
+        "url": "https://launchpad.net/meliae",
+        "packages": ["meliae"],
+        "scripts": ["strip_duplicates.py"],
         "ext_modules": ext
     }
 
@@ -37,13 +38,13 @@
         return
 
     kwargs["cmdclass"] = {"build_ext": build_ext}
-    ext.append(Extension("memory_dump._scanner",
-                         ["memory_dump/_scanner.pyx",
-                          "memory_dump/_scanner_core.c"]))
-    ext.append(Extension("memory_dump._loader",
-                         ["memory_dump/_loader.pyx"]))
-    ext.append(Extension("memory_dump._intset",
-                         ["memory_dump/_intset.pyx"]))
+    ext.append(Extension("meliae._scanner",
+                         ["meliae/_scanner.pyx",
+                          "meliae/_scanner_core.c"]))
+    ext.append(Extension("meliae._loader",
+                         ["meliae/_loader.pyx"]))
+    ext.append(Extension("meliae._intset",
+                         ["meliae/_intset.pyx"]))
 
     setup(**kwargs)
 



More information about the bazaar-commits mailing list