Ask Your Question

ROS 2 xacro executable will not run

asked 2020-06-10 11:28:33 -0500

max_a gravatar image

updated 2022-06-27 03:50:43 -0500

gvdhoorn gravatar image

I downloaded ROS 2 dashing onto my windows 10 device through this link: and then followed this tutorial to set up the xacro package since it was not included in the ROS 2 installation:

However, now when I try to run "ros2 run xacro xacro --xacro-ns custom.xacro > custom.urdf" in the dev_ws that I cloned the xacro package to, I get the following:

Traceback (most recent call last):
  File "C:\dev\ros2-dashing\Scripts\", line 11, in <module>
load_entry_point('ros2cli==0.7.10', 'console_scripts', 'ros2')()
  File "C:\dev\ros2-dashing\Lib\site-packages\ros2cli\", line 69, in main
    rc = extension.main(parser=parser, args=args)
  File "C:\dev\ros2-dashing\Lib\site-packages\ros2run\command\", line 72, in main
    return run_executable(path=path, argv=args.argv, prefix=prefix)
  File "C:\dev\ros2-dashing\Lib\site-packages\ros2run\api\", line 61, in run_executable
    process = subprocess.Popen(cmd)
  File "c:\python37\lib\", line 800, in __init__
    restore_signals, start_new_session)
  File "c:\python37\lib\", line 1207, in _execute_child
OSError: [WinError 193] %1 is not a valid Win32 application

Would anyone be able to help me with this?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2022-06-24 00:09:23 -0500

danzimmerman gravatar image

updated 2022-06-24 00:13:00 -0500

This seems to still be a problem two years later on Galactic. xacro is a simple Python script with a shebang and doesn't register as a Windows executable.

It looks like there's a PR in progress, but not yet merged:

I uninstalled the ros-galactic-xacro package (I'm using Robostack) and installed xacro from source using

That fixes the issue for me:

(galactic-clean) C:\Code\ros2\galactic_ws>ros2 run xacro xacro
Usage: xacro [options] <input>

xacro: error: expected exactly one input file as argument
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2020-06-10 11:28:33 -0500

Seen: 391 times

Last updated: Jun 27