Skip to content

Importing the warnings package is missing #36

@apoyet

Description

@apoyet

Hi,

On the "optics_specific_tools.py" file, it is possible to skip the make thin of the sequence by setting:

sliceFactor=0

This will trigger the following:

else:
        warnings.warn('The sequences are not thin!')

However this will lead to an error as the warnings python package is not imported anywhere (at least to my knowledge).

Simply adding:

import warnings

in the "optics_specific_tools.py" file solves this issue. But I think it would be worth having it by default in order to avoid this small error.

Thanks a lot.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions