tomography / scanscripts

Experiment scanning scripts at APS
http://scanscripts.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
1 stars 2 forks source link

library module name starting with numbers are not allowed #12

Closed decarlof closed 6 years ago

decarlof commented 6 years ago

I just found out that

import tomo.32id.txm

fails (library module cannot start with a number) if you are OK I would issue a pull request to replace:

32id -> aps32id 2bm -> aps2bm ...

Also I think we need to separate the library module (tomo_scan_lib.py, txm.py and txm_pv.py) from the rest (that just uses the library module). For example tomo_fly_scan.py should go under "Sector 32-ID Scripts" and in this function

from tomo_scan_lib import *

should be replaced by

from tomo.tomo_scan_lib import *

Finally another thing to consider is to change the name of the library from 'tomo' to 'scans' => from tomo_scan_lib import becomes from scans.tomo_scan_lib import or even better (if we rename tomo_scan_lib into tomo): from scans.tomo import *

canismarko commented 6 years ago

Fixed in 374e17a3c6dc6dc64e3f90c33524ccf465aab533

dgursoy commented 6 years ago

How about using aps_32id instead of aps32id? Then It will match with the dxchange beamline definitions.

canismarko commented 6 years ago

I actually went with the aps_32id style, and for exactly that reason. =P