View Issue Details

IDProjectCategoryView StatusLast Update
0003422OpenFOAMBugpublic2020-01-09 10:29
Reporterjfp6Assigned Tohenry 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
PlatformGNU/LinuxOSUbuntuOS Version18.04
Product Versiondev 
Fixed in Versiondev 
Summary0003422: foamJob not reading macro for numberOfSubdomains in decomposePar
DescriptionBetween version dev-263a22a67bf4 and dev-7cd43ea5f827 the functionality of how foamJob writes the number of cores for mpirun from a macro has changed. Using dev-263a22a67bf4 I could use a macro to specify the numberOfSubdomains and when running foamJob it would write "...Executing: /usr/bin/mpirun -np 4 ...". With dev-7cd43ea5f827 it populates with "...Executing: /usr/bin/mpirun -np $test ..." instead of the number. The macro is read correctly from decomposePar when running decomposePar for both versions. When using "foamJob decomposePar", the macro also works for both versions. This problem only exists for foamJob when populating the number of cores for mpirun.
Steps To ReproduceFor the damBreak case (or any case that is ready to be decomposed) add the file test with the contents test 4;

echo "test 4;" > system/test

Next modify the system/decomposePar file to have the following two lines at the beginning:

#include "./system/test"
numberOfSubdomains $test;

Run the case manually:

blockMesh
setFields
decomposePar
foamJob -p interFoam

"...Executing: /usr/bin/mpirun -np $test ..." will fail to run because the number of cores is not specified.
TagsNo tags attached.

Activities

henry

2020-01-07 19:44

manager   ~0011045

foamJob has not changed but the default expansion behavior of foamDictionary (which foamJob uses to get the numberOfSubdomains) has. I will push a fix for this change in default behavior shortly.

jfp6

2020-01-07 20:35

reporter   ~0011046

Thanks for the clarification and your help with the fix.

henry

2020-01-07 21:26

manager   ~0011047

This should be resolved by commit d8209247b13a7bf0a7074cff71060735cefd2498

Issue History

Date Modified Username Field Change
2020-01-07 19:03 jfp6 New Issue
2020-01-07 19:44 henry Note Added: 0011045
2020-01-07 20:35 jfp6 Note Added: 0011046
2020-01-07 21:26 henry Note Added: 0011047
2020-01-09 10:29 henry Assigned To => henry
2020-01-09 10:29 henry Status new => resolved
2020-01-09 10:29 henry Resolution open => fixed
2020-01-09 10:29 henry Fixed in Version => dev