...bashrc: No such file or directory

A subforum specific to the development of the OpenFoam-based workbenches ( Cfd https://github.com/qingfengxia/Cfd and CfdOF https://github.com/jaheyns/CfdOF )

Moderator: oliveroxtoby

shogan50
Posts: 7
Joined: Sun Feb 14, 2021 4:25 pm
Location: Mukilteo, Wa
Contact:

...bashrc: No such file or directory

Postby shogan50 » Wed Feb 24, 2021 1:39 am

I'm trying to get up and running cfdOF on windows and am getting stalled attempting to run snappyhexmesh. Something is calling the wrong path and it isn't obvious to me where it comes from. Any help appreciated.

Code: Select all

17:25:41  Executing: C:\Users\scotth\AppData\Roaming\ESI-OpenCFD\OpenFOAM\v2012\\msys64\usr\bin\bash --login -O expand_aliases -c echo Sourcing OpenFOAM environment...; source $HOME/OpenFOAM/OpenFOAM-v/etc/bashrc; export PATH=$FOAM_LIBBIN/msmpi:$FOAM_LIBBIN:$WM_THIRD_PARTY_DIR/platforms/linux64MingwDPInt32/lib:$PATH; cd "/c/Users/scotth/AppData/Local/Temp/meshCase" && ./Allmesh
17:25:41  Raw command:  ['D:/FreeCAD_0.19.24054-Win-Conda_vc14.x-x86_64/bin\\python.exe', '-u', 'C:\\Users\\scotth\\AppData\\Roaming\\FreeCAD\\Mod\\CfdOF-master\\WindowsRunWrapper.py', 'C:\\Users\\scotth\\AppData\\Roaming\\ESI-OpenCFD\\OpenFOAM\\v2012\\\\msys64\\usr\\bin\\bash', '--login', '-O', 'expand_aliases', '-c', 'echo Sourcing OpenFOAM environment...; source $HOME/OpenFOAM/OpenFOAM-v/etc/bashrc; export PATH=$FOAM_LIBBIN/msmpi:$FOAM_LIBBIN:$WM_THIRD_PARTY_DIR/platforms/linux64MingwDPInt32/lib:$PATH; cd "/c/Users/scotth/AppData/Local/Temp/meshCase" && ./Allmesh']
17:25:42  Sourcing OpenFOAM environment...
17:25:42  /usr/bin/bash: /home/ofuser/OpenFOAM/OpenFOAM-v/etc/bashrc: No such file or directory
In the last line

Code: Select all

/usr/bin/bash: /home/ofuser/OpenFOAM/OpenFOAM-v/etc/bashrc:
I believe this should be:

Code: Select all

/usr/bin/bash: /home/ofuser/OpenFOAM/OpenFOAM-v2012/etc/bashrc
I'm also running a linux version with its own issues and thought the windows one had passed the dependency checker, but checking just now.

Code: Select all

Error parsing OpenFOAM version string directory
this path exists and install directory is set to it.

Code: Select all

C:\Users\scotth\AppData\Roaming\ESI-OpenCFD\OpenFOAM\v2012\
I believe I suffered the same issue with V.184.


OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24054 (Git)
Build type: Release
Branch: master
Hash: ed873038025277f220dfaa058599a0dfbb435835
Python version: 3.8.6
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)
User avatar
oliveroxtoby
Posts: 500
Joined: Fri Dec 23, 2016 9:43 am
Location: South Africa

Re: ...bashrc: No such file or directory

Postby oliveroxtoby » Wed Feb 24, 2021 6:30 am

shogan50 wrote: Wed Feb 24, 2021 1:39 am I'm trying to get up and running cfdOF on windows and am getting stalled attempting to run snappyhexmesh. Something is calling the wrong path and it isn't obvious to me where it comes from. Any help appreciated.

Code: Select all

17:25:41  Executing: C:\Users\scotth\AppData\Roaming\ESI-OpenCFD\OpenFOAM\v2012\\msys64\usr\bin\bash --login -O expand_aliases -c echo Sourcing OpenFOAM environment...; source $HOME/OpenFOAM/OpenFOAM-v/etc/bashrc; export PATH=$FOAM_LIBBIN/msmpi:$FOAM_LIBBIN:$WM_THIRD_PARTY_DIR/platforms/linux64MingwDPInt32/lib:$PATH; cd "/c/Users/scotth/AppData/Local/Temp/meshCase" && ./Allmesh
17:25:41  Raw command:  ['D:/FreeCAD_0.19.24054-Win-Conda_vc14.x-x86_64/bin\\python.exe', '-u', 'C:\\Users\\scotth\\AppData\\Roaming\\FreeCAD\\Mod\\CfdOF-master\\WindowsRunWrapper.py', 'C:\\Users\\scotth\\AppData\\Roaming\\ESI-OpenCFD\\OpenFOAM\\v2012\\\\msys64\\usr\\bin\\bash', '--login', '-O', 'expand_aliases', '-c', 'echo Sourcing OpenFOAM environment...; source $HOME/OpenFOAM/OpenFOAM-v/etc/bashrc; export PATH=$FOAM_LIBBIN/msmpi:$FOAM_LIBBIN:$WM_THIRD_PARTY_DIR/platforms/linux64MingwDPInt32/lib:$PATH; cd "/c/Users/scotth/AppData/Local/Temp/meshCase" && ./Allmesh']
17:25:42  Sourcing OpenFOAM environment...
17:25:42  /usr/bin/bash: /home/ofuser/OpenFOAM/OpenFOAM-v/etc/bashrc: No such file or directory
In the last line

Code: Select all

/usr/bin/bash: /home/ofuser/OpenFOAM/OpenFOAM-v/etc/bashrc:
I believe this should be:

Code: Select all

/usr/bin/bash: /home/ofuser/OpenFOAM/OpenFOAM-v2012/etc/bashrc
I'm also running a linux version with its own issues and thought the windows one had passed the dependency checker, but checking just now.

Code: Select all

Error parsing OpenFOAM version string directory
this path exists and install directory is set to it.

Code: Select all

C:\Users\scotth\AppData\Roaming\ESI-OpenCFD\OpenFOAM\v2012\
I believe I suffered the same issue with V.184.


OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24054 (Git)
Build type: Release
Branch: master
Hash: ed873038025277f220dfaa058599a0dfbb435835
Python version: 3.8.6
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)
This seems to be a bug caused by the trailing '\' on the OpenFOAM path that you set. I will push a fix shortly, but for now if you just remove it you should be ok.
User avatar
oliveroxtoby
Posts: 500
Joined: Fri Dec 23, 2016 9:43 am
Location: South Africa

Re: ...bashrc: No such file or directory

Postby oliveroxtoby » Wed Feb 24, 2021 8:16 am

oliveroxtoby wrote: Wed Feb 24, 2021 6:30 am
shogan50 wrote: Wed Feb 24, 2021 1:39 am
This seems to be a bug caused by the trailing '\' on the OpenFOAM path that you set. I will push a fix shortly, but for now if you just remove it you should be ok.
This should be resolved now.
shogan50
Posts: 7
Joined: Sun Feb 14, 2021 4:25 pm
Location: Mukilteo, Wa
Contact:

Re: ...bashrc: No such file or directory

Postby shogan50 » Wed Feb 24, 2021 5:07 pm

Thanks.
FYI, the '\' is really persistent. I can get it to pass a dependency check, but it comes back after closing preferences window. Still can't run OF. This is true of a restart as well. How long does it take for your fix to propagate to the releases?
User avatar
oliveroxtoby
Posts: 500
Joined: Fri Dec 23, 2016 9:43 am
Location: South Africa

Re: ...bashrc: No such file or directory

Postby oliveroxtoby » Wed Feb 24, 2021 7:15 pm

shogan50 wrote: Wed Feb 24, 2021 5:07 pm Thanks.
FYI, the '\' is really persistent. I can get it to pass a dependency check, but it comes back after closing preferences window. Still can't run OF. This is true of a restart as well. How long does it take for your fix to propagate to the releases?
Are you closing the window or clicking 'OK'? It won't apply your change unless you click OK or Apply.

Updates are independent of the releases as it is a addon module - go to Tools | Addon Manager | CfdOF and click Install/Update.
shogan50
Posts: 7
Joined: Sun Feb 14, 2021 4:25 pm
Location: Mukilteo, Wa
Contact:

Re: ...bashrc: No such file or directory

Postby shogan50 » Wed Feb 24, 2021 7:34 pm

Are you closing the window or clicking 'OK'? It won't apply your change unless you click OK or Apply.
I'm definitely clicking apply. It seems to always come back next time I open preferences.

Thanks for clarification on updating.
shogan50
Posts: 7
Joined: Sun Feb 14, 2021 4:25 pm
Location: Mukilteo, Wa
Contact:

Re: ...bashrc: No such file or directory

Postby shogan50 » Wed Feb 24, 2021 7:46 pm

I just updated via addon mgr. The trailing backslash is still reappearing, but I think I figured something out. It looks like there are two instances of the cfdOF plugin. There are two identical general tabs in preferences. If I clear the backslash from both before exiting, it doesn't appear to come back. There is also this message in the Report view upon opening FreeCAD.

Code: Select all

11:34:28  During initialization the error ""'CfdOFWorkbench' already exists."" occurred in C:\Users\scotth\AppData\Roaming\FreeCAD\Mod\CfdOF-master\InitGui.py
11:34:28  Please look into the log file for further information
shogan50
Posts: 7
Joined: Sun Feb 14, 2021 4:25 pm
Location: Mukilteo, Wa
Contact:

Re: ...bashrc: No such file or directory

Postby shogan50 » Wed Feb 24, 2021 7:53 pm

Figured it out, I think. I had followed the instructions for manual install of cfdOF in V.18 due to the addon manager bug. I downloaded V.19 and updated cfdOF via addon mgr, but the addon and manual versions use different folder names, so it installed beside rather than update. Deleting what I believe the the manual installed one is seems to have fixed the issue.