Erik Fasterius
03/23/2026, 7:42 AMNico Trummer
03/23/2026, 8:39 AMNico Trummer
03/23/2026, 8:40 AMErik Fasterius
03/23/2026, 8:48 AMErik Fasterius
03/23/2026, 11:20 AMFatal error: cannot create 'R_TempDir' on my Mac when they had worked just fine before. Any particular thing that changed in the images that might have affected this that you can think of?Erik Fasterius
03/23/2026, 11:20 AMNico Trummer
03/23/2026, 11:20 AMErik Fasterius
03/23/2026, 11:21 AMNico Trummer
03/23/2026, 11:24 AMErik Fasterius
03/23/2026, 11:25 AMErik Fasterius
03/23/2026, 12:56 PMcontainerOptions in each R module in conf/modules.config. It seems that the /tmp dir is owned by root, while the commonly used runOptions include linking host user inside the container, which makes /tmp unwritable by the user - I assume this is only because of the emulation happening on Apple Silicon. What made it harder to diagnose was that R for some reason tries to set the tempdir before even finishing initialising itself, meaning that any code I added to the template file was never run (so you can't set the tempdir inside the R template, since it'll never get the chance to run). Since the modules aren't using the script: directive we can't specifically export a new TMPDIR environment variable there either, while setting it in the module-specific options. Would love a prettier solution if you have one 😅 I'll make the rest of the modules with this change as well to make sure it works across the board.Nico Trummer
03/23/2026, 1:00 PMSince the modules aren't using theI don't think this is true, all the modules in the pipeline use thedirective we can't specifically export a new TMPDIR environment variable there eitherscript:
script directive (in combination with a template). An example of how to set env variables properly in python scripts is hereErik Fasterius
03/23/2026, 1:03 PMErik Fasterius
03/23/2026, 1:03 PMNico Trummer
03/23/2026, 1:05 PMErik Fasterius
03/23/2026, 1:06 PMErik Fasterius
03/23/2026, 1:09 PMcontainerOptions could be more apt. What do you think?Erik Fasterius
03/23/2026, 1:13 PMbeforeScript 'export TMPDIR=.' doesn't seem to workNico Trummer
03/23/2026, 1:14 PMNico Trummer
03/23/2026, 1:15 PMWhen the process is containerized (using the container directive), thewill be executed in the container only if the executor is container-native (e.g. cloud batch executors, Kubernetes). Otherwise, thebeforeScriptwill be executed outside the container.beforeScript
Erik Fasterius
03/23/2026, 1:16 PMNico Trummer
03/23/2026, 1:18 PMErik Fasterius
03/23/2026, 1:21 PMcontainerOptions is a Nextflow thing it will indeed be applied to all container technologies, but since this is just setting an environment variable to point to the working directory, I'd guess that it was fine? I'm not a proper software engineer though, so if you have other ideas I'm happy for another solution.Erik Fasterius
03/23/2026, 1:22 PMcontainerOptions = '--env TMPDIR=.' inside the affected modules in conf/modules.configNico Trummer
03/23/2026, 1:24 PMErik Fasterius
03/23/2026, 1:25 PMNico Trummer
03/23/2026, 1:28 PMNico Trummer
03/23/2026, 1:28 PMErik Fasterius
03/23/2026, 1:29 PMErik Fasterius
03/23/2026, 1:30 PMNico Trummer
03/23/2026, 1:42 PMErik Fasterius
03/23/2026, 1:42 PMNico Trummer
03/23/2026, 1:43 PMErik Fasterius
03/23/2026, 1:44 PMNico Trummer
03/23/2026, 1:47 PMErik Fasterius
03/23/2026, 1:48 PMErik Fasterius
03/23/2026, 1:49 PMNico Trummer
03/23/2026, 1:50 PMNico Trummer
03/23/2026, 1:51 PMErik Fasterius
03/23/2026, 1:51 PMdev branch, same error for meNico Trummer
03/23/2026, 1:52 PMNico Trummer
03/23/2026, 1:54 PMErik Fasterius
03/23/2026, 1:59 PMErik Fasterius
03/23/2026, 1:59 PMNico Trummer
03/23/2026, 2:00 PMNico Trummer
03/23/2026, 2:00 PMNico Trummer
03/23/2026, 2:00 PMErik Fasterius
03/23/2026, 2:00 PMErik Fasterius
03/23/2026, 2:01 PMErik Fasterius
03/23/2026, 2:02 PMNico Trummer
03/23/2026, 2:06 PMErik Fasterius
03/23/2026, 2:07 PMErik Fasterius
03/23/2026, 2:08 PMErik Fasterius
03/23/2026, 2:09 PM