Skip to content

update rust-g to 3.9.0 and use formatted_timestamp for human_readable_timestamp #6695

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

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

Conversation

Absolucy
Copy link
Member

About The Pull Request

This updates rust-g to 3.9.0, and also improves some code related to logging a little:

  • rustg_unix_timestamp is now a define instead of a proc
    • this is somewhat of a hot call, as it gets called every time a log entry is written, so this is prolly worth it imo
  • /datum/log_holder/proc/human_readable_timestamp() now uses rustg_formatted_timestamp, instead of the current stupid BS with time2text and then adding fractional seconds by using splittext on the unix timestamp???
    • i've confirmed that the output of the old and new code are identical.

this is a port of tgstation/tgstation#91121, which itself was a partial port of #6540, my old PR here

Why It's Good For The Game

because using splittext on a timestamp to add a fractional part is stupid, when we can now just use rust-g to format it all in one go.

Changelog

No user-facing changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code: Improvement exactly what it says on the tin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant