From f139a7d28248fc488badc349cf902a7c2e2871bc Mon Sep 17 00:00:00 2001 From: garen Date: Mon, 10 Jun 2013 21:28:48 -0400 Subject: [PATCH 1/2] resolve issue \#1172: don't divide by zero --- sphinx/__init__.py | 4 ++-- sphinx/builders/__init__.py | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/sphinx/__init__.py b/sphinx/__init__.py index c091a6776..cc0a66031 100644 --- a/sphinx/__init__.py +++ b/sphinx/__init__.py @@ -15,8 +15,8 @@ import sys from os import path -__version__ = '1.2b1' -__released__ = '1.2b1' # used when Sphinx builds its own docs +__version__ = '1.2b1-xgen1-' +__released__ = '1.2b1-xgen1-' # used when Sphinx builds its own docs package_dir = path.abspath(path.dirname(__file__)) diff --git a/sphinx/builders/__init__.py b/sphinx/builders/__init__.py index 3ff5a161c..026cbdb77 100644 --- a/sphinx/builders/__init__.py +++ b/sphinx/builders/__init__.py @@ -354,6 +354,8 @@ class Builder(object): # for the rest, determine how many documents to write in one go ndocs = len(docnames) chunksize = min(ndocs // nproc, 10) + if chunksize == 0: + chunksize = 1 nchunks, rest = divmod(ndocs, chunksize) if rest: nchunks += 1 From d57589a1eb09a91e70909b53c2047742b8b23e57 Mon Sep 17 00:00:00 2001 From: tychoish Date: Sun, 30 Jun 2013 23:20:44 +0000 Subject: [PATCH 2/2] removed version change --- sphinx/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sphinx/__init__.py b/sphinx/__init__.py index cc0a66031..c091a6776 100644 --- a/sphinx/__init__.py +++ b/sphinx/__init__.py @@ -15,8 +15,8 @@ import sys from os import path -__version__ = '1.2b1-xgen1-' -__released__ = '1.2b1-xgen1-' # used when Sphinx builds its own docs +__version__ = '1.2b1' +__released__ = '1.2b1' # used when Sphinx builds its own docs package_dir = path.abspath(path.dirname(__file__))