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

Fix memory reporting with sysinfo 0.16 #142

Merged
merged 1 commit into from Nov 20, 2022
Merged

Conversation

plugwash
Copy link
Contributor

With commit 6a2e754 when I run "cargo test --all --all-targets --no-default-features --features build,cargo,si" I see

cargo:rustc-env=VERGEN_SYSINFO_TOTAL_MEMORY=16 GB

Which correctly reflects the ram in my system.

However with 2bb2b49 and current master I see.

cargo:rustc-env=VERGEN_SYSINFO_TOTAL_MEMORY=16 xB

The cause of this is that sysinfo 0.16 changed the units for reporting memory from kilobytes to bytes, this commit updates the reported units to match. I also added TB to the list of possible units. Computers with terabytes of memory do exist nowadays.

sysinfo 0.16 changed the units for reporting memory from kilobytes to bytes,
this commit updates the reported units to match. I also added TB to the list
of possible units. Computers with terabytes of memory do exist nowadays.
@codecov
Copy link

codecov bot commented Nov 20, 2022

Codecov Report

Merging #142 (fd8ca9b) into master (a157623) will increase coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #142      +/-   ##
==========================================
+ Coverage   93.80%   93.82%   +0.02%     
==========================================
  Files          11       11              
  Lines        1195     1199       +4     
==========================================
+ Hits         1121     1125       +4     
  Misses         74       74              
Impacted Files Coverage Δ
src/feature/si.rs 97.53% <100.00%> (+0.04%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@CraZySacX CraZySacX merged commit 8b0aa4f into rustyhorde:master Nov 20, 2022
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

2 participants