You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have a python application that uses logging, importing nipype modifies your logging configuration. This results in multiple log messages being printed to the screen when you go to use the logger that you set up.
Actual behavior
Importing from nipype.interfaces.ants import N4BiasFieldCorrection reaults in log messages being printed to the console twice.
Expected behavior
When you import nipype, it should have no effect on any logging system in your application
How to replicate the behavior
import logging
from nipype.interfaces.ants import N4BiasFieldCorrection
logger = logging.getLogger('root')
logger.addHandler(logging.StreamHandler())
logger.warning("This should really only be appearing once...")
Script/Workflow details
N/a
Please put URL to code or code here (if not too long).
Summary
If you have a python application that uses logging, importing nipype modifies your logging configuration. This results in multiple log messages being printed to the screen when you go to use the logger that you set up.
Actual behavior
Importing from nipype.interfaces.ants import N4BiasFieldCorrection reaults in log messages being printed to the console twice.
Expected behavior
When you import nipype, it should have no effect on any logging system in your application
How to replicate the behavior
Script/Workflow details
N/a
Please put URL to code or code here (if not too long).
Platform details:
MacOS
Please paste the output of:
python -c "import nipype; print(nipype.get_info()); print(nipype.__version__)"
{'pkg_path': '/Users/jonpdeaton/anaconda3/lib/python3.6/site-packages/nipype', 'commit_source': 'installation', 'commit_hash': '7d3966f', 'nipype_version': '1.0.3', 'sys_version': '3.6.4 |Anaconda custom (64-bit)| (default, Mar 12 2018, 20:05:31) \n[GCC 4.2.1 Compatible Clang 4.0.1 (tags/RELEASE_401/final)]', 'sys_executable': '/Users/jonpdeaton/anaconda3/bin/python', 'sys_platform': 'darwin', 'numpy_version': '1.14.2', 'scipy_version': '0.19.1', 'networkx_version': '2.0', 'nibabel_version': '2.2.1', 'traits_version': '4.6.0'}
1.0.3
Execution environment
Anaconda, Python 3.6
Choose one
The text was updated successfully, but these errors were encountered: