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

feat: logs are now timestamped, their level is written. #21

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

DaymareOn
Copy link
Owner

  • The logs previously only included in debug version are now in
    the release version too.
  • The performance logs explaining how many skeletons are active are
    now verbose instead of debug.

- The logs previously only included in debug version are now in
  the release version too.
- The performance log explaining how many skeletons are active are
  now verbose instead of debug.
@alandtse
Copy link
Collaborator

FYI, the first word in a commit should be a verb

Copy link
Collaborator

@alandtse alandtse left a comment

Choose a reason for hiding this comment

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

Are you sure SKSE doesn't have the ability to add time stamps through a format string? It seems odd to have to manually do it in our own class.

@DaymareOn
Copy link
Owner Author

Are you sure SKSE doesn't have the ability to add time stamps through a format string? It seems odd to have to manually do it in our own class.

I don't see anything in their logging code about this. Maybe they didn't want to have to manage the related perf and multi-threading challenges?

@DaymareOn
Copy link
Owner Author

FYI, the first word in a commit should be a verb

Argh... Thank you.
When squashing the commit, I'll put "feat: timestamp logs, write log levels".

@DaymareOn
Copy link
Owner Author

Are you sure SKSE doesn't have the ability to add time stamps through a format string? It seems odd to have to manually do it in our own class.

I don't see anything in their logging code about this. Maybe they didn't want to have to manage the related perf and multi-threading challenges?

po3 logs have timestamps. I'll have to go look how he did it.

@DaymareOn
Copy link
Owner Author

Are you sure SKSE doesn't have the ability to add time stamps through a format string? It seems odd to have to manually do it in our own class.

I don't see anything in their logging code about this. Maybe they didn't want to have to manage the related perf and multi-threading challenges?

po3 logs have timestamps. I'll have to go look how he did it.

My understanding is that he didn't use the SKSE logging system, but reimplemented it with stdlog:
https://github.com/powerof3/BaseObjectSwapper/blob/master/src/main.cpp

@DaymareOn
Copy link
Owner Author

His way is better than mine, because he lets stdlog handle the time retrieval and the related multi-threading challenges.
I'll see if I can use stdlog.

@DaymareOn DaymareOn marked this pull request as draft March 23, 2022 08:46
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