Nette Framework 2.3.10 released

3 years ago

David Grudl
Nette Core | 6849
+
+17
-
  • composer.json: relaxed dependencies to ~2.3.x
  • Http\RequestFactory: Fixed possible remoteAddr spoofing (issue nette/http#87)
  • PresenterFactory: added possibility to configure mapping via array
  • Presenter: isLinkCurrent is compatible with PHP 7 typehints
  • RouteList: added warmupCache()
  • JsonResponse: sends utf-8 charset
  • DI\ContainerBuilder: unused parameters check when generating factory
  • DI\Compiler: support for removing services via name: no
  • Mail\Message: improved regexp for seaching embedded images
  • SafeStream: unregister protocols in cleaner way
  • Html::__toString() prints better error message
  • Latte: exception ‘Template is not valid UTF-8 stream’ provides line number
  • Latte: supports PHP 7 coalesce operator
  • Tracy\Bar: added CPU usage to info panel
  • TracyExtension: added option ‘showBar’

For the details you can have a look at: application, di, http + previous, mail, reflection, safe-stream, utils, latte, tracy.

3 years ago

ZZromanZZ
Member | 87
+
0
-

Correct me if I'm wrong, new Tracy info panel “CPU usage” is immediate value collected by kernel function getrusage. In our case, it's called in Debugger::enable(), it`s in most cases called somewhere in bootstrap.

So shouldn't be CPU usage in Tracy panel named “Initial CPU usage user + system” or something less confusing then only “CPU usage user + system”?

BTW measuring CPU time can be very treacherous.

3 years ago

greeny
Member | 406
+
0
-

The method getrusage is called here in template, which is loaded at the moment when Tracy bar gets rendered, which happens at the end of script through register_shutdown_handler function. So it measures real usage (maybe a bit more, since initialzation and rendering of Tracy bar is partially included as well).

3 years ago

ZZromanZZ
Member | 87
+
0
-

OK, I see it now