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

local_timezone: gracefully handle retrieval errors on Darwin #792

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tpwrules
Copy link

@tpwrules tpwrules commented Jan 6, 2024

In some sandbox environments, the program may not have permission to access /etc/localtime or it may not exist.

Catch any exceptions accessing and parsing its value and return UTC by default to avoid crashing the program.

Pull Request Check List

  • Added tests for changed code.
  • Updated documentation for changed code.

Copy link

codspeed-hq bot commented Jan 9, 2024

CodSpeed Performance Report

Merging #792 will not alter performance

Comparing tpwrules:darwin-error-handling (a4d98ce) with master (3e3fec6)

Summary

✅ 1 untouched benchmarks

In some sandbox environments, the program may not have
permission to access /etc/localtime or it may not exist.

Catch any exceptions accessing and parsing its value and return UTC by
default to avoid crashing the program.
@tpwrules tpwrules force-pushed the darwin-error-handling branch from a4d98ce to ba57bed Compare January 9, 2024 16:57
@tpwrules
Copy link
Author

tpwrules commented Jan 9, 2024

Fixed formatting.

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.

1 participant