Skip to content

[help] Unable to use logger when branching #1202

Closed Answered by wlandau
philiporlando asked this question in Help
Discussion options

You must be logged in to vote

This happens because the crew worker processes don't know about the settings you specified using logger::log_appender(). If you call set_logger(your_log_file, overwrite = FALSE) inside test_logger(), the log and all the expected lines seem to show up. Since your targets are running in parallel, it is good practice to use separate logs so the processes do not compete for access to a single file. The behavior in those cases is unpredictable: https://www.techtarget.com/searchstorage/definition/race-condition#:~:text=Race%20conditions%20are%20most%20commonly,common%20issue%20for%20multithreaded%20applications.

Replies: 1 comment 8 replies

Comment options

You must be logged in to vote
8 replies
@wlandau
Comment options

@philiporlando
Comment options

@philiporlando
Comment options

@wlandau
Comment options

@philiporlando
Comment options

Answer selected by philiporlando
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants