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

Improve handling of os-release files #2553

Merged
merged 8 commits into from May 4, 2023

Conversation

kropidlowsky
Copy link
Contributor

@kropidlowsky kropidlowsky commented May 2, 2023

Description

Closes #2500 .

Add in parseOSRelease support for:

  • unquoting values
  • dealing with more than one = in values - there should be only one delimiter per line

Readiness checklist

  • I added/updated unit tests.
  • I added/updated integration/compatibility tests.
  • I added/updated comments and checked rendering.
  • I made spot refactorings.
  • I updated user documentation.
  • I ran task all, and it passed.
  • I ensured that PR title is good enough for the changelog.
  • (for maintainers only) I set Reviewers (@FerretDB/core), Labels, Project and project's Sprint fields.
  • I marked all done items in this checklist.

@kropidlowsky kropidlowsky requested a review from a team as a code owner May 2, 2023 15:25
@AlekSi AlekSi requested review from rumyantseva and removed request for chilagrow May 2, 2023 15:26
@codecov
Copy link

codecov bot commented May 2, 2023

Codecov Report

Merging #2553 (d043627) into main (9884aec) will decrease coverage by 38.09%.
The diff coverage is 80.00%.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##             main    #2553       +/-   ##
===========================================
- Coverage   65.14%   27.05%   -38.09%     
===========================================
  Files         410      410               
  Lines       20062    20071        +9     
===========================================
- Hits        13070     5431     -7639     
- Misses       6053    14069     +8016     
+ Partials      939      571      -368     
Impacted Files Coverage Δ
internal/handlers/common/parse_osrelease.go 77.27% <80.00%> (+0.34%) ⬆️

... and 134 files with indirect coverage changes

Flag Coverage Δ
integration 5.04% <0.00%> (-52.89%) ⬇️
mongodb 5.04% <0.00%> (-0.01%) ⬇️
pg ?
unit 25.69% <80.00%> (+0.02%) ⬆️

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

@AlekSi AlekSi added this to the v1.1.0 milestone May 2, 2023
@AlekSi AlekSi added the code/enhancement Some user-visible feature could work better label May 2, 2023
@AlekSi AlekSi changed the title improve handling os-release files Improve handling of os-release files May 2, 2023
@AlekSi AlekSi enabled auto-merge (squash) May 2, 2023 18:09
Copy link
Contributor

@w84thesun w84thesun left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution! Please take a look at the small suggestion I propose.

internal/handlers/common/parse_osrelease.go Outdated Show resolved Hide resolved
auto-merge was automatically disabled May 3, 2023 15:29

Head branch was pushed to by a user without write access

Co-authored-by: Dmitry <dmitry.eremenko@ferretdb.io>
@kropidlowsky
Copy link
Contributor Author

@w84thesun thank you for the proposal! Updated

@w84thesun w84thesun enabled auto-merge (squash) May 3, 2023 15:33
Copy link
Contributor

@w84thesun w84thesun left a comment

Choose a reason for hiding this comment

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

LGTM!

@w84thesun w84thesun merged commit 71b70aa into FerretDB:main May 4, 2023
22 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code/enhancement Some user-visible feature could work better
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Improve how we identify Linux version in hostInfo command
3 participants