Skip to content

StreamLogger#283

Open
JanTvrdik wants to merge 2 commits intonette:masterfrom
JanTvrdik:pr/stream_logger
Open

StreamLogger#283
JanTvrdik wants to merge 2 commits intonette:masterfrom
JanTvrdik:pr/stream_logger

Conversation

@JanTvrdik
Copy link
Contributor

  • bug fix? no
  • new feature? yes
  • BC break? no

implements #280

@dg
Copy link
Member

dg commented Feb 22, 2018

Isn't better this

Debugger::setLogger(new StreamLogger);
Debugger::enable();

than this?

Debugger::enable(Debugger::DETECT, new StreamLogger);

@JanTvrdik
Copy link
Contributor Author

The issue is that in Nette you're never actually calling Debugger::enable(), because there is $configurator->enableDebugger(). So, the actual comparison is

Tracy\Debugger::setLogger(new Tracy\StreamLogger('php://stderr'));

$configurator = new Nette\Configurator();
$configurator->enableDebugger();

vs.

$configurator = new Nette\Configurator();
$configurator->enableDebugger(new Tracy\StreamLogger('php://stderr'));

@JanTvrdik
Copy link
Contributor Author

When I think about it now, the logic could be moved to Nette\Configurator – but it would create disparity between Tracy\Debuger::enable() and Nette\Configurator::enableDebugger() signatures.

@dg
Copy link
Member

dg commented Feb 25, 2018

create disparity between

It does not matter.

@dg dg force-pushed the master branch 4 times, most recently from d13a9ce to 7f24887 Compare February 25, 2018 23:58
@dg dg force-pushed the master branch 8 times, most recently from 427177a to 7ac33a2 Compare March 26, 2018 11:48
@dg dg force-pushed the master branch 11 times, most recently from 8675719 to 51fdf8a Compare April 6, 2018 06:37
@dg dg force-pushed the master branch 14 times, most recently from 13fabe3 to fefc1ba Compare May 17, 2018 13:11
@dg dg force-pushed the master branch 6 times, most recently from cd36780 to ab9cc75 Compare May 28, 2018 12:47
@dg dg force-pushed the master branch 2 times, most recently from c5c5bab to 0d0dbd8 Compare August 13, 2018 17:05
@dg dg mentioned this pull request Aug 27, 2018
@dg dg force-pushed the master branch 3 times, most recently from 17ddd81 to 9cb1b0f Compare September 30, 2018 18: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.

2 participants