[h5py] 169/455: Minor updates

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Thu Jul 2 18:19:29 UTC 2015


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

ghisvail-guest pushed a commit to annotated tag 1.3.0
in repository h5py.

commit 5f63cbd2fc31a2b366c1c8fe40058cb1d7eef45d
Author: andrewcollette <andrew.collette at gmail.com>
Date:   Sun Nov 30 23:15:56 2008 +0000

    Minor updates
---
 MANIFEST.in                 |  2 --
 docs/source/guide/build.rst |  7 ++++---
 docs/source/guide/hl.rst    | 43 ++++++++++++++++++++++++++++++++-----------
 setup.py                    |  9 +++++----
 4 files changed, 41 insertions(+), 20 deletions(-)

diff --git a/MANIFEST.in b/MANIFEST.in
index cb088fe..afb4695 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -2,7 +2,5 @@ include MANIFEST.in
 include LICENSE.txt
 include INSTALL.txt
 include README.txt
-include CHANGES.txt
-include docs.cfg
 recursive-include h5py *.py *.pyx *.pxd *.pxi *.h *.c *.hdf5
 recursive-include licenses *
diff --git a/docs/source/guide/build.rst b/docs/source/guide/build.rst
index 94a178f..54a5b85 100644
--- a/docs/source/guide/build.rst
+++ b/docs/source/guide/build.rst
@@ -17,7 +17,7 @@ On :ref:`Windows <windows>`, HDF5 is provided as part of the integrated
 installer for h5py.  On UNIX platforms (:ref:`Linux and OS-X <linux>`), you
 must provide HDF5 yourself.  The following HDF5 versions are supported:
 
-* 1.6.5, 1.6.7, 1.6.8, 1.8.0, 1.8.1, 1.8.2
+* 1.6.5, 1.6.6, 1.6.7, 1.6.8, 1.8.0, 1.8.1, 1.8.2
 
 **The best solution is to install HDF5 via a package manager.** If you must
 install yourself from source, keep in mind that you *must* build as a dynamic
@@ -58,12 +58,13 @@ debugging level.
 
 Requires
 --------
-- Unix-like environment (created/tested on 32-bit Intel linux)
 - Python with headers for development
 - Numpy_ 1.0.3 or higher
 - HDF5_ 1.6.5 or higher, including 1.8.X versions
+- Cython_ 0.9.8.1.1 or higher
+
+- Unix-like environment (created/tested on 32-bit Intel linux)
 - A working compiler for distutils
-- (Optionally) Cython_ 0.9.8.1.1 or higher
 
 .. _Numpy: http://numpy.scipy.org/
 .. _HDF5: http://www.hdfgroup.com/HDF5
diff --git a/docs/source/guide/hl.rst b/docs/source/guide/hl.rst
index 6c809ee..01a4598 100644
--- a/docs/source/guide/hl.rst
+++ b/docs/source/guide/hl.rst
@@ -19,8 +19,8 @@ package namespace; you can do::
 
     >>> from h5py import *  # or from h5py import File, etc.
 
-General info
-============
+General information about h5py and HDF5
+=======================================
 
 Paths in HDF5
 -------------
@@ -33,14 +33,25 @@ root group ``/`` (represented by the :class:`File` class) at the base.
 Wherever a name or path is called for, it may be relative or absolute.
 Constructs like ``..`` (parent group) are allowed.
 
-Metadata
---------
 
-Every object in HDF5 supports metadata in the form of "attributes", which are
-small, named bits of data.  :class:`Group`, :class:`Dataset` and even
-:class:`File` objects each carry a dictionary-like object which exposes this
-behavior, named ``<obj>.attrs``.  This is the correct way to store metadata
-in HDF5 files.
+Exceptions
+----------
+
+Standard Python exceptions like TypeError and ValueError are raised in
+response to inappropriate arguments.  When an error is encountered by the
+HDF5 library itself, h5py.H5Error (or more commonly, a subclass) is raised.
+For example::
+
+    >>> try:
+    >>>     myfile = h5py.File(some_name)
+    >>> except TypeError:
+    >>>     print "Argument some_name isn't a string!"
+    >>> except H5Error:
+    >>>     print "Problem opening the file %s" % some_name
+
+In practice, all H5Error exceptions contain a useful stacktrace generated
+by the library itself, including a good description of where and why the error
+occurred.
 
 Library configuration
 ---------------------
@@ -69,9 +80,19 @@ filters may cause issues when attempting to read files created with HDF5 1.8
 from an installation using HDF5 1.6.  It's generally best to use the same
 version of HDF5 for all your applications.
 
+Metadata
+--------
 
-Files
-=====
+Every object in HDF5 supports metadata in the form of "attributes", which are
+small, named bits of data.  :class:`Group`, :class:`Dataset` and even
+:class:`File` objects each carry a dictionary-like object which exposes this
+behavior, named ``<obj>.attrs``.  This is the correct way to store metadata
+in HDF5 files.
+
+--------------------------------------------------------
+
+File Objects
+============
 
 To open an HDF5 file, just instantiate the File object directly::
 
diff --git a/setup.py b/setup.py
index c5c5a92..c170d4d 100644
--- a/setup.py
+++ b/setup.py
@@ -261,7 +261,6 @@ class cybuild(build):
 
         pxi_str = \
 """# This file is automatically generated.  Do not edit.
-# HDF5: %(HDF5)s
 
 DEF H5PY_VERSION = "%(VERSION)s"
 
@@ -275,8 +274,7 @@ DEF H5PY_THREADS = %(THREADS)d  # Enable thread-safety and non-blocking reads
 """
         return pxi_str % {"VERSION": VERSION, "API_MAX": self.api,
                     "API_16": True, "API_18": self.api == 18,
-                    "DEBUG": 10 if self.diag else 0, "THREADS": not self.no_threads,
-                    "HDF5": "Default" if self.hdf5 is None else self.hdf5}
+                    "DEBUG": 10 if self.diag else 0, "THREADS": not self.no_threads}
 
     def compile_cython(self, modules):
         """ Regenerate the C source files for the build process.
@@ -455,7 +453,10 @@ class new_sdist(sdist):
     def run(self):
         if os.path.exists('MANIFEST'):
             os.remove('MANIFEST')
-        shutil.copyfile(reduce(op.join, ('docs', 'source', 'build.rst')), 'INSTALL.txt')
+
+        ipath = reduce(op.join, ('docs', 'source', 'build.rst'))
+        if op.exists(ipath):
+            shutil.copyfile(ipath, 'INSTALL.txt')
 
         sdist.run(self)
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/h5py.git



More information about the debian-science-commits mailing list