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

Set installed property for installed platform when core search is executed #2223

Merged

Conversation

MatteoPologruto
Copy link
Contributor

@MatteoPologruto MatteoPologruto commented Jun 21, 2023

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?

Code enhancement

What is the current behavior?

The installed property is never set.

./arduino-cli core install arduino:avr --format json
./arduino-cli core search "" --format json | jq '.[]  | select(.id == "arduino:avr") | .installed'
null

What is the new behavior?

The installed property is set if the platform is installed.

./arduino-cli core install arduino:avr --format json
./arduino-cli core search "" --format json | jq '.[]  | select(.id == "arduino:avr") | .installed'
"1.8.6"

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

No

@MatteoPologruto MatteoPologruto added type: enhancement Proposed improvement topic: code Related to content of the project itself labels Jun 21, 2023
@MatteoPologruto MatteoPologruto self-assigned this Jun 21, 2023
@MatteoPologruto MatteoPologruto changed the title Set installed property for installed platform when core search is executed Set installed property for installed platform when core search is executed Jun 21, 2023
@codecov
Copy link

codecov bot commented Jun 21, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (9bc2afc) 62.95% compared to head (641f64e) 62.95%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2223   +/-   ##
=======================================
  Coverage   62.95%   62.95%           
=======================================
  Files         220      220           
  Lines       19476    19478    +2     
=======================================
+ Hits        12261    12263    +2     
  Misses       6132     6132           
  Partials     1083     1083           
Flag Coverage Δ
unit 62.95% <100.00%> (+<0.01%) ⬆️

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

Impacted Files Coverage Δ
commands/core/search.go 84.21% <100.00%> (+0.57%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@MatteoPologruto MatteoPologruto marked this pull request as ready for review June 21, 2023 11:22
@MatteoPologruto MatteoPologruto linked an issue Jun 21, 2023 that may be closed by this pull request
3 tasks
@MatteoPologruto MatteoPologruto merged commit eca9d9a into arduino:master Jun 21, 2023
@MatteoPologruto MatteoPologruto deleted the core-search-set-installed branch June 21, 2023 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: code Related to content of the project itself type: enhancement Proposed improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

core search: please set the installed property for installed platforms
3 participants