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

Small logger refactor #301

Merged
merged 3 commits into from
Jul 31, 2018
Merged

Small logger refactor #301

merged 3 commits into from
Jul 31, 2018

Conversation

Corfiot
Copy link
Contributor

@Corfiot Corfiot commented Jul 31, 2018

Log header created more simply
(Workflow test)

Corfiot added 2 commits July 31, 2018 19:14
Log header created more simply
Duplicate body names break the logging system (IOException: Sharing violation on path...)
bodies.Add(currentBody.name, currentBody);
Events.OnLoaderLoadBody.Fire(currentBody, bodyNode);
Logger.Default.Log("[Kopernicus]: Configuration.Loader: Loaded Body: " + currentBody.name);
if (bodies.ContainsKey(currentBody.name) )
Copy link
Member

Choose a reason for hiding this comment

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

This check should be done even before creating the logger for it, since creating a logger with an already existing bodyname would either crash, overwrite the old log, or mix them, which doesn't sound like the best idea to me.

Copy link
Contributor Author

@Corfiot Corfiot Jul 31, 2018

Choose a reason for hiding this comment

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

This is the error I'm trying to fix. But this should not be in this pull request. It was supposed to only be the first commit. Apparently I needed to make a branch and pull request from there?

@Corfiot
Copy link
Contributor Author

Corfiot commented Jul 31, 2018

Should be OK now for merging. Sorry, still learning

@StollD StollD merged commit cd3838e into Kopernicus:master Jul 31, 2018
@StollD
Copy link
Member

StollD commented Jul 31, 2018

Small tip: Use different branches for different projects / pull requests. That way you cannot accidentally commit something into a different PR.

Also, thanks for the contribution!

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