Reciprocal space

I added the ImportError and Travis is working (test passing) Thanks

From: Thomas A Caswell <notifications@github.com<mailto:notifications@github.com>>
Reply-To: NSLS-II/NSLS2 <reply@reply.github.com<mailto:reply@reply.github.com>>
Date: Tuesday, August 12, 2014 at 12:25 PM
To: NSLS-II/NSLS2 <NSLS2@noreply.github.com<mailto:NSLS2@noreply.github.com>>
Cc: Sameera Abeykoon <sameera@bnl.gov<mailto:sameera@bnl.gov>>
Subject: Re: [NSLS2] Reciprocal space (#59)


In nsls2/recip.py:

>  import numpy as np
>  import logging
>  logger = logging.getLogger(__name__)
> +import time
> +import operator
> +
> +try:
> +    import src.ctrans as ctrans
> +except:
> +    try:
> +        import ctrans
> +    except:
> +        pass


You should be catching the ImportError

try:
    import ctrans
except ImportError:
    ctrans = None



Also see https://github.com/soft-matter/pims/blob/master/pims/api.py

—
Reply to this email directly or view it on GitHub<https://github.com/NSLS-II/NSLS2/pull/59/files#r16124315>.