Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add warning for pennbbl Docker image #870

Merged
merged 1 commit into from
Nov 13, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions qsiprep/cli/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
def main():
"""Entry point."""
import gc
import os
import sys
from multiprocessing import Manager, Process
from os import EX_SOFTWARE
Expand All @@ -41,6 +42,31 @@ def main():

parse_args()

# Raise a warning about PennBBL/QSIPrep being deprecated
in_container = False
# Check for Docker
if os.path.exists("/.dockerenv"):
in_container = True

# Check for Apptainer/Singularity
if os.path.exists("/.singularity.d") or os.path.exists("/.apptainer.d"):
in_container = True

# Check for environment variables
if os.getenv("SINGULARITY_NAME") or os.getenv("APPTAINER_NAME"):
in_container = True

if in_container:
print(
"""\
**************************************************************
WARNING: The pennbbl/qsiprep Docker image has been DEPRECATED.
Please use the pennlinc/qsiprep image instead.
**************************************************************
""",
file=sys.stderr,
)

if "pdb" in config.execution.debug:
from qsiprep.utils.debug import setup_exceptionhook

Expand Down