Skip to content

env={} instead of env=matlab_env #17

@jhgoebbert

Description

@jhgoebbert

Hello,

thank you for this great package!
I came across one issue while adding it to our software stage.

Xvfb ist started by from https://github.com/mathworks/matlab-proxy/blob/main/matlab_proxy/app_state.py#L644
This calls mw.create_xvfb_process(xvfb_cmd, dpipe) from
https://github.com/mathworks/matlab-proxy/blob/main/matlab_proxy/util/mw.py#L260
with env={} for the call

    xvfb = await asyncio.create_subprocess_exec(
        *xvfb_cmd, close_fds=False, env=env, stderr=asyncio.subprocess.PIPE
    )

Hence, the command Xvfb must be located on system paths.
For the start of matlab the environment is correctly set with matlab_env
https://github.com/mathworks/matlab-proxy/blob/main/matlab_proxy/app_state.py#L686
But this is not the case for Xvfb

On our systems Xvfb is loaded via a module. So I created a wrapper script called Xvfb located at some location added to $PATH.
But this wrapper script is not found because of env={} instead of env=matlab_env.

Metadata

Metadata

Labels

bugSomething isn't workingfixed

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions