Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix monitor init handling #2728

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

Merged
cmaglie merged 4 commits into arduino:master from cmaglie:fix_monitor_init_handling
Oct 11, 2024
Merged

Conversation

Copy link
Member

@cmaglie cmaglie commented Oct 10, 2024

Please check if the PR fulfills these requirements

See how to contribute

  • The PR has no duplicates (please search among the Pull Requests
    before creating one)
  • The PR follows
    our contributing guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)
  • UPGRADING.md has been updated with a migration guide (for breaking changes)
  • configuration.schema.json updated if new parameters are added.

What kind of change does this PR introduce?

Fix a deadlock in the gRPC Monitor command that keeps the package manager busy for no reason.

What is the current behavior?

While a call to gRPC Monitor command is running, other calls may be blocked, in particular the Init call. This lead to the Arduino IDE bug described in #2719

What is the new behavior?

The Monitor command doesn't lock the package manager anymore.

Does this PR introduce a breaking change, and is titled accordingly?

No

Other information

Fix #2719

@cmaglie cmaglie self-assigned this Oct 10, 2024
@cmaglie cmaglie added type: imperfection Perceived defect in any part of project topic: gRPC Related to the gRPC interface labels Oct 10, 2024
@cmaglie cmaglie added this to the Arduino CLI v1.1.0 milestone Oct 10, 2024
...to terminate
otherwise the test will fail on Windows when the cleanup function tries to remove the
executable:
Error Trace:	D:/a/arduino-cli/arduino-cli/internal/integrationtest/environment.go:46
 D:/a/arduino-cli/arduino-cli/internal/integrationtest/environment.go:56
 D:/a/arduino-cli/arduino-cli/internal/integrationtest/environment.go:56
 D:/a/arduino-cli/arduino-cli/internal/integrationtest/environment.go:62
 D:/a/arduino-cli/arduino-cli/internal/integrationtest/daemon/daemon_concurrency_test.go:127
Error: Received unexpected error:
 remove C:\Users\runneradmin\AppData\Local\Temp\cli2489057723\A\packages\builtin\tools\serial-monitor0円.14.1\serial-monitor.exe: Access is denied.
Test: TestInitAndMonitorConcurrency
Copy link

codecov bot commented Oct 10, 2024
edited
Loading

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.68%. Comparing base (ac6ec6d) to head (a812e1a).
Report is 2 commits behind head on master.

Additional details and impacted files
@@ Coverage Diff @@
## master #2728 +/- ##
=======================================
 Coverage 67.68% 67.68% 
=======================================
 Files 234 234 
 Lines 22285 22285 
=======================================
 Hits 15083 15083 
 Misses 6017 6017 
 Partials 1185 1185 
Flag Coverage Δ
unit 67.68% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@cmaglie cmaglie merged commit ea09108 into arduino:master Oct 11, 2024
98 checks passed
@cmaglie cmaglie deleted the fix_monitor_init_handling branch October 11, 2024 08:51
@per1234 per1234 added the topic: code Related to content of the project itself label Oct 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@MatteoPologruto MatteoPologruto Awaiting requested review from MatteoPologruto

2 more reviewers

@alessio-perugini alessio-perugini alessio-perugini approved these changes

@umbynos umbynos umbynos approved these changes

Reviewers whose approvals may not affect merge requirements
Labels
topic: code Related to content of the project itself topic: gRPC Related to the gRPC interface type: imperfection Perceived defect in any part of project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

cc.arduino.cli.commands.v1.ArduinoCoreService.Init hangs if Monitor is running

AltStyle によって変換されたページ (->オリジナル) /