[Checkins] SVN: zope.deferredimport/trunk/ Initial commit of zope.deferredimport for eggification.

Baiju M baiju.m.mail at gmail.com
Sun Oct 8 02:16:22 EDT 2006


Log message for revision 70563:
  Initial commit of zope.deferredimport for eggification.
  

Changed:
  _U  zope.deferredimport/trunk/
  A   zope.deferredimport/trunk/CHANGES.txt
  A   zope.deferredimport/trunk/INSTALL.txt
  A   zope.deferredimport/trunk/MANIFEST.in
  A   zope.deferredimport/trunk/README.txt
  A   zope.deferredimport/trunk/setup.cfg.in
  A   zope.deferredimport/trunk/setup.py
  A   zope.deferredimport/trunk/src/
  A   zope.deferredimport/trunk/src/zope/
  A   zope.deferredimport/trunk/src/zope/__init__.py
  A   zope.deferredimport/trunk/test.py

-=-

Property changes on: zope.deferredimport/trunk
___________________________________________________________________
Name: svn:ignore
   + bin
build
dist
lib
setup.cfg


Added: zope.deferredimport/trunk/CHANGES.txt
===================================================================
--- zope.deferredimport/trunk/CHANGES.txt	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/CHANGES.txt	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,3 @@
+zope.deferredimport Package Changelog
+=====================================
+


Property changes on: zope.deferredimport/trunk/CHANGES.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zope.deferredimport/trunk/INSTALL.txt
===================================================================
--- zope.deferredimport/trunk/INSTALL.txt	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/INSTALL.txt	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,83 @@
+Installing This Package
+=======================
+
+Prerequisites
+-------------
+
+The installation steps below assume that you have the cool new 'setuptools'
+package installed in your Python.  Here is where to get it:
+
+  $ wget http://peak.telecommunity.com/dist/ez_setup.py
+  $ /path/to/your/python ez_setup.py # req. write access to 'site-packages'
+
+
+  - Docs for EasyInstall:
+    http://peak.telecommunity.com/DevCenter/EasyInstall
+
+  - Docs for setuptools:
+    http://peak.telecommunity.com/DevCenter/setuptools
+
+  - Docs for eggs:
+    http://peak.telecommunity.com/DevCenter/PythonEggs
+
+
+Installing a Development Checkout
+---------------------------------
+
+Check out the package from subversion:
+
+  $ svn co svn+ssh://svn.zope.org/repos/main/zope.deferredimport/trunk \
+    src/zope.deferredimport
+  $ cd src/zope.deferredimport
+
+Install it as a "devlopment egg" (which also installs its "hard"
+dependencies):
+
+  $ /path/to/your/python setup.py devel
+
+The installation of dependency eggs uses the 'setup.cfg' file in
+the checkout.  You can supply '--find-links' on the command line to
+point it at a non-standard package repository.
+
+
+Running the Tests
+-----------------
+
+To test the package, you will also need the 'zope.testing' package, which
+can't (yet) be automatically installed.  Eventually, you should be able to
+type:
+
+  $ /path/to/your/python setup.py test
+
+and have it install the "testing dependencies."  Today, the workaround
+is to install it manually:
+
+  $ /path/to/easy_install --find-links="...." zope.testing
+
+You can then run the tests (finally) from the checkout directory:
+
+  $ /path/to/your/python test.py
+    Running:
+      .............
+    Ran 16 tests with 0 failures and 0 errors in 0.094 seconds.
+
+
+Installing a Source Distribution
+--------------------------------
+
+You can also install it from a source distribution:
+
+  $ /path/to/easy_install --find-links="...." -eb src zope.deferredimport
+  $ cd src/zope.proxy
+  $ /path/to/your/python setup.py devel
+
+
+Installing a Binary Egg
+-----------------------
+
+Install the package as a "binary egg" (which also installs its "hard"
+dependencies):
+
+  $ /path/to/easy_install --find-links="...." zope.proxy
+
+


Property changes on: zope.deferredimport/trunk/INSTALL.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zope.deferredimport/trunk/MANIFEST.in
===================================================================
--- zope.deferredimport/trunk/MANIFEST.in	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/MANIFEST.in	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1 @@
+exclude setup.cfg


Property changes on: zope.deferredimport/trunk/MANIFEST.in
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zope.deferredimport/trunk/README.txt
===================================================================
--- zope.deferredimport/trunk/README.txt	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/README.txt	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,49 @@
+zope.deferredimport Package Readme
+==================================
+
+Overview
+--------
+
+Often, especially for package modules, you want to import names for
+convenience, but not actually perform the imports until necessary.
+The zope.deferredimport package provided facilities for defining names
+in modules that will be imported from somewhere else when used.  You
+can also cause deprecation warnings to be issued when a variable is
+used, but we'll get to that later.
+
+The zope.deferredimport.define function can be used to define one or
+more names to be imported when they are accessed.  Simply provide
+names as keyword arguments with import specifiers as values.  The
+import specifiers are given as strings of the form "module:name",
+where module is the dotted name of the module and name is a, possibly
+dotted, name of an object within the module.
+
+Changes
+-------
+
+See CHANGES.txt.
+
+Installation
+------------
+
+See INSTALL.txt.
+
+
+Developer Resources
+-------------------
+
+- Subversion browser:
+
+  http://svn.zope.org/zope.deferredimport/
+
+- Read-only Subversion checkout:
+
+  $ svn co svn://svn.zope.org/repos/main/zope.deferredimport/trunk
+
+- Writable Subversion checkout:
+
+  $ svn co svn+ssh://userid@svn.zope.org/repos/main/zope.deferredimport/trunk
+
+- Note that the 'src/zope/deferredimport' package is acutally a 'svn:externals' link
+  to the corresponding package in the Zope3 trunk (or to a specific tag,
+  for released versions of the package).


Property changes on: zope.deferredimport/trunk/README.txt
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zope.deferredimport/trunk/setup.cfg.in
===================================================================
--- zope.deferredimport/trunk/setup.cfg.in	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/setup.cfg.in	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,6 @@
+[development]
+depends = zope.testing
+
+[egg_info]
+tag_build = .dev
+tag_svn_revision = 1


Property changes on: zope.deferredimport/trunk/setup.cfg.in
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zope.deferredimport/trunk/setup.py
===================================================================
--- zope.deferredimport/trunk/setup.py	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/setup.py	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,52 @@
+##############################################################################
+#
+# Copyright (c) 2006 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+"""Setup for zope.deferredimport package
+
+$Id$
+"""
+
+import os
+
+try:
+    from setuptools import setup, Extension
+except ImportError, e:
+    from distutils.core import setup, Extension
+
+setup(name='zope.deferredimport',
+      version='3.3-dev',
+      url='http://svn.zope.org/zope.deferredimport',
+      license='ZPL 2.1',
+      description='Zope Deferredimport',
+      author='Zope Corporation and Contributors',
+      author_email='zope3-dev at zope.org',
+      long_description="The zope.deferredimport.define function can be used to"
+                       "define one or more names to be imported when they are"
+                       "accessed.  Simply provide names as keyword arguments"
+                       "with import specifiers as values.  The import"
+                       "specifiers are given as strings of the form"
+                       "'module:name', where module is the dotted name of"
+                       "the module and name is a, possibly dotted, name of"
+                       "an object within the module.",
+
+      packages=['zope', 'zope.deferredimport'],
+      package_dir = {'': 'src'},
+
+      namespace_packages=['zope',],
+      tests_require = ['zope.testing'],
+      install_requires=['zope.interface',
+                        'zope.proxy'],
+      include_package_data = True,
+
+      zip_safe = False,
+      )


Property changes on: zope.deferredimport/trunk/setup.py
___________________________________________________________________
Name: svn:eol-style
   + native


Property changes on: zope.deferredimport/trunk/src
___________________________________________________________________
Name: svn:ignore
   + zope.deferredimport.egg-info



Property changes on: zope.deferredimport/trunk/src/zope
___________________________________________________________________
Name: svn:externals
   + deferredimport svn://svn.zope.org/repos/main/Zope3/trunk/src/zope/deferredimport


Added: zope.deferredimport/trunk/src/zope/__init__.py
===================================================================
--- zope.deferredimport/trunk/src/zope/__init__.py	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/src/zope/__init__.py	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,7 @@
+# this is a namespace package
+try:
+    import pkg_resources
+    pkg_resources.declare_namespace(__name__)
+except ImportError:
+    import pkgutil
+    __path__ = pkgutil.extend_path(__path__, __name__)


Property changes on: zope.deferredimport/trunk/src/zope/__init__.py
___________________________________________________________________
Name: svn:eol-style
   + native

Added: zope.deferredimport/trunk/test.py
===================================================================
--- zope.deferredimport/trunk/test.py	2006-10-08 05:56:04 UTC (rev 70562)
+++ zope.deferredimport/trunk/test.py	2006-10-08 06:16:21 UTC (rev 70563)
@@ -0,0 +1,36 @@
+#!/usr/bin/env python
+##############################################################################
+#
+# Copyright (c) 2004 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.0 (ZPL).  A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+"""Sample test script using zope.testing.testrunner
+
+see zope.testing testrunner.txt
+
+$Id$
+"""
+
+import os, sys
+
+src = os.path.join(os.path.split(sys.argv[0])[0], 'src')
+sys.path.insert(0, src) # put at beginning to avoid one in site_packages
+
+from zope.testing import testrunner
+
+defaults = [
+    '--path', src,
+    '--package', 'zope.deferredimport',
+    '--tests-pattern', '^tests$',
+    ]
+
+sys.exit(testrunner.run(defaults))
+


Property changes on: zope.deferredimport/trunk/test.py
___________________________________________________________________
Name: svn:eol-style
   + native



More information about the Checkins mailing list