bids-apps / CPAC

BIDS Application for the Configurable Pipeline for the Analysis of Connectomes (C-PAC)
Apache License 2.0
14 stars 18 forks source link

trusty version not showing mount correctly #25

Closed jdkent closed 6 years ago

jdkent commented 6 years ago

Setup:

Singularity container on CENTOS 7 server as the entry to a HPC cluster.

Behavior:

singularity shell jdkent_cpac_latest-2018-01-24-be00acf97a2f.img 
Singularity: Invoking an interactive shell within container...

Singularity.jdkent_cpac_latest-2018-01-24-be00acf97a2f.img> $ python
Python 2.7.13 |Continuum Analytics, Inc.| (default, Dec 20 2016, 23:09:15) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
Anaconda is brought to you by Continuum Analytics.
Please check out: http://continuum.io/thanks and https://anaconda.org
>>> import nipype
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/__init__.py", line 49, in <module>
    from .pipeline import Node, MapNode, JoinNode, Workflow
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/pipeline/__init__.py", line 10, in <module>
    from .engine import Node, MapNode, JoinNode, Workflow
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/pipeline/engine/__init__.py", line 12, in <module>
    from .workflows import Workflow
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/pipeline/engine/workflows.py", line 41, in <module>
    from ...interfaces.base import (traits, InputMultiPath, CommandLine,
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/interfaces/__init__.py", line 12, in <module>
    from .io import DataGrabber, DataSink, SelectFiles
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/interfaces/io.py", line 38, in <module>
    from ..utils.filemanip import copyfile, list_to_filename, filename_to_list
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/utils/filemanip.py", line 266, in <module>
    _cifs_table = _generate_cifs_table()
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/utils/filemanip.py", line 259, in _generate_cifs_table
    reverse=True)
  File "/usr/local/bin/miniconda/lib/python2.7/site-packages/nipype/utils/filemanip.py", line 258, in <lambda>
    key=lambda x: len(x[0]),
IndexError: list index out of range

The error is coming from the mount command

Example

Singularity.jdkent_cpac_latest-2018-01-24-be00acf97a2f.img> $ mount
singularity on / type rootfs (rw)

mount: warning: /etc/mtab is not writable (e.g. read-only filesystem).
       It's possible that information reported by mount(8) is not
       up to date. For actual information about system mount points
       check the /proc/mounts file.

While the input expected is just singularity on / type rootfs (rw): see nipype code

chrisgorgo commented 6 years ago

This seems more like a nipype issue. Different mount outputs should've been handled more robustly.

jdkent commented 6 years ago

It seemed to only happen on the centos 7 distribution with singularity, it worked fine with my local ubuntu computer on both docker and singularity. It appears to be a very niche error, but agreed, nipype could handle warnings better. Made a pull request working around that error to move forward here.