Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wait for ros binaries before returning #245

Closed
wants to merge 6 commits into from

Conversation

flynneva
Copy link
Contributor

Description

  • Does this PR check in generated JS code (npm run build)?

Signed-off-by: Evan Flynn <evanflynn.msu@gmail.com>
@flynneva
Copy link
Contributor Author

#243

@christophebedard
Copy link
Member

I was wondering why the tests didn't catch this, so I took a look. Weirdly enough, it seemed to work fine in a previous test 😅 https://github.com/ros-tooling/setup-ros/runs/942469149#step:5:374

I don't know a lot about async or JS/TS, but maybe it's about timing?

Could you try this branch with your own repo and see if it actually works? Like uses: flynneva/setup-ros@windows-fix

@flynneva
Copy link
Contributor Author

flynneva commented Aug 16, 2020

running now on grbl_ros.

it shouldnt matter, but I also put it for the linux ci tests just to make sure nothing funky goes on there

@flynneva
Copy link
Contributor Author

it looks like this change successfully does what its trying to do - download the ros2 binaries for windows. but it looks like later on there are still failures...maybe from not sourcing the ros2 install?

@christophebedard
Copy link
Member

christophebedard commented Aug 16, 2020

it looks like this change successfully does what its trying to do - download the ros2 binaries for windows.

🎊

but it looks like later on there are still failures...maybe from not sourcing the ros2 install?

Only one way to find out 😁 can you try this branch with ros-tooling/action-ros-ci#306 in your repo?

@flynneva
Copy link
Contributor Author

flynneva commented Aug 16, 2020

re-running because it looks like a failure on one of the mac runs caused all windows/mac runs to be canceled.

it looks like for mac there is the same issue....only stops at rosdep init and doesnt actually install ROS2 binaries

@christophebedard
Copy link
Member

christophebedard commented Aug 16, 2020

it looks like for mac there is the same issue....only stops at rosdep init and doesnt actually install ROS2 binaries

I don't think the action even tries to install binaries on Mac: https://github.com/ros-tooling/setup-ros/blob/1a56282ce2ee5651bf97ad6229b5fa2260773b16/src/setup-ros-osx.ts. Not sure what's the intention here. Also, the README (https://github.com/ros-tooling/setup-ros#modifications-performed-by-the-action) only says that it installs system dependencies but does not mention installing (or having the option to install) ROS/ROS 2 itself, so I'm a bit confused.

Ohh wait, binary install isn't yet supported on OS X: #107

@christophebedard
Copy link
Member

christophebedard commented Aug 16, 2020

Ohh wait, binary install isn't yet supported on OS X: #107

So maybe try to remove the MacOS part for now? This way we can continue with the Windows stuff.

@flynneva
Copy link
Contributor Author

i think this PR is OK - it does what is expected and downloads the ROS2 binaries.

there are more issues with action-ros-ci i think - looks like the "isWindows" doesnt actually return true if its windows because the windows commands are still being run with "bash".

@christophebedard
Copy link
Member

i think this PR is OK - it does what is expected and downloads the ROS2 binaries.

Definitely!

there are more issues with action-ros-ci i think - looks like the "isWindows" doesnt actually return true if its windows because the windows commands are still being run with "bash".

By default it doesn't show you the actual command. If you click on a command ("Invoking ...") it'll show the full command, which seems to be fine, e.g.:

C:\Windows\system32\cmd.exe /E:ON /V:OFF /S /C call "%programfiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" amd64 & "C:\Program Files\Git\bin\bash.exe" -c "colcon test --event-handlers console_cohesion+ --pytest-with-coverage --return-code-on-test-failure --packages-select grbl_ros

@emersonknapp
Copy link
Contributor

Are you actually seeing changed behavior on your test runs against this branch? My understanding is that the action runner runs dist/index.js which needs to be generated locally and checked in with the PR

npm install
npm run build

Should give you the outputs you need

@christophebedard
Copy link
Member

christophebedard commented Aug 18, 2020

oh, right. Maybe it's just luck/timing then?

I assume it should be fine, since runWindows() simply returns a promise that is awaited in setup-ros.ts, but we do see a difference:

first one stops at rosdep init but the second one goes on and downloads+unzips the binary.

@flynneva flynneva closed this Aug 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants