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

Windows support for chrome runner #2324

Merged
merged 1 commit into from
Oct 13, 2021
Merged

Windows support for chrome runner #2324

merged 1 commit into from
Oct 13, 2021

Conversation

janbiedermann
Copy link
Member

No description provided.

lib/opal/cli_runners/chrome.rb Outdated Show resolved Hide resolved
lib/opal/cli_runners/chrome.rb Outdated Show resolved Hide resolved
@hmdne hmdne added this to the v1.3 milestone Oct 7, 2021
@hmdne
Copy link
Member

hmdne commented Oct 7, 2021

The minitest failure is random I think, I re-ran the tasks.

@janbiedermann
Copy link
Member Author

The minitest failure is random I think, I re-ran the tasks.

Its running faulty code

@janbiedermann
Copy link
Member Author

Alright, for the others mspec-chrome / minitest-strict-chrome, i have no idea why it cant connect to chrome, i cant reproduce, maybe a timing issue? Or it too ran faulty code? No idea how and why that happens.

@hmdne
Copy link
Member

hmdne commented Oct 7, 2021

Those errors are random and it's a known issue.

@hmdne
Copy link
Member

hmdne commented Oct 7, 2021

We will merge it on Wednesday at the latest.

Copy link
Member

@elia elia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!
You think there's a way to cover windows support for these runners to the CI?
Let me know if you need assistance for that.
Also we need to squash all the "fixup" commits into a single one (I can do that before merging).

]

Kernel.exec(*cmd)
end
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the windows solution is universal and can work on any system I'm in favor of only using that one, so we have less code to maintain and to reason about

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is outdated :)

Process.kill('HUP', chrome_pid) if chrome_pid
case RbConfig::CONFIG['host_os']
when /mswin|msys|mingw|cygwin|bccwin|wince|emc/
Process.kill("KILL", pid) unless system("taskkill /f /t /pid #{pid} >NUL 2>NUL")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a way to avoid the call to taskkill?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No way. Windows has its weirdnesses and taskkill seems to be the best solution out there.

@hmdne
Copy link
Member

hmdne commented Oct 9, 2021

Nice! You think there's a way to cover windows support for these runners to the CI?

In a previous patchset (#2309, also fixing opal-repl on Windows) I tried running things on Windows and they ran smoothly. But I ran it via MSYS, and this patchset removes a need for MSYS. @janbiedermann had also a few test failures and he's ironing them out. I think the issue with a Windows action for mspec will be... that it will be very slow. Maybe we can consider just running the opal suite.

- Use correct node separator for NODE_PATH on Windows
- Pass dir and emulate exec a bit on Windows
- Use Gem.win_platform?, match supported plattform to ruby, simplify run
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.

3 participants