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

Split off logging and utils #62

Merged
merged 4 commits into from
Jan 19, 2023

Conversation

Qubus0
Copy link
Collaborator

@Qubus0 Qubus0 commented Jan 19, 2023

This needs to be merged after

Breaking changes:
Removed:

ModLoader.
mod_log
dev_log

Use the following instead:

ModLoaderUtils.
log_fatal()
log_error()
log_warning()
log_info()
log_success()
log_debug()
log_debug_json_print()

closes #21

@Qubus0 Qubus0 mentioned this pull request Jan 19, 2023
@otDan
Copy link
Member

otDan commented Jan 19, 2023

probably switching back to the single method and just adding an enum to specify the log type is better

@Qubus0
Copy link
Collaborator Author

Qubus0 commented Jan 19, 2023

Any particular reason for that? That would mean having to reference the enum every single time for logging, e.g.

ModLoaderUtils.mod_log("some message here: %s" % some_value, ModLoaderUtils.verbosity_level.INFO, LOG_NAME)
# and this if you also want the json print included in the same method
ModLoaderUtils.mod_log("some message here: %s" % some_value, ModLoaderUtils.verbosity_level.INFO, LOG_NAME, true)

compared to this.

ModLoaderUtils.log_info("some message here: %s" % some_value, LOG_NAME)

I feel like it's much more concise and better to understand at a glance

@Qubus0 Qubus0 marked this pull request as ready for review January 19, 2023 22:44
Copy link
Member

@otDan otDan left a comment

Choose a reason for hiding this comment

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

well other than that comment, everything seems to be in place and working

Copy link
Collaborator

@ithinkandicode ithinkandicode left a comment

Choose a reason for hiding this comment

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

Lookin' good man!

@Qubus0 Qubus0 merged commit 8aadd85 into GodotModding:main Jan 19, 2023
@Qubus0 Qubus0 deleted the split_off_logging_and_utils branch January 19, 2023 22:57
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.

Different log levels for mod_log
3 participants