Kint - a powerful and modern PHP debugging tool.

Overview

Kint - debugging helper for PHP developers

Screenshot

What am I looking at?

At first glance Kint is just a pretty replacement for var_dump(), print_r() and debug_backtrace().

However, it's much, much more than that. You will eventually wonder how you developed without it.

Installation

One of the main goals of Kint is to be zero setup.

Download the file and simply

<?php

require 'kint.phar';

Or, if you use Composer:

composer require kint-php/kint --dev

Usage

<?php

Kint::dump($GLOBALS, $_SERVER); // pass any number of parameters
d($GLOBALS, $_SERVER); // or simply use d() as a shorthand

Kint::trace(); // Debug backtrace
d(1); // Debug backtrace shorthand

s($GLOBALS); // Basic output mode

~d($GLOBALS); // Text only output mode

Kint::$enabled_mode = false; // Disable kint
d('Get off my lawn!'); // Debugs no longer have any effect

Tips & Tricks

  • Kint is enabled by default, set Kint::$enabled_mode = false; to turn it completely off.
    The best practice is to enable Kint in a development environment only - so even if you accidentally leave a dump in production, no one will know.
  • See the buttons on the right of the output? Click them to open a new tab, show the access path for the value, or show a search box.
  • To see the output where you called Kint instead of the docked toolbar at the bottom of the page add the line Kint\Renderer\RichRenderer::$folder = false; right after you include Kint.
  • There are a couple of real-time modifiers you can use:
    • ~d($var) this call will output in plain text format.
    • +d($var) will disregard depth level limits and output everything.
      Careful, this can hang your browser on large objects!
    • !d($var) will expand the output automatically.
    • -d($var) will attempt to ob_clean the previous output and flush after printing.
    • You can combine modifiers too: ~+d($var)
  • Double clicking the + sign will open/close it and all its children.
  • Triple clicking the + sign in will open/close everything on the page.
  • Add heavy classes to the blacklist to improve performance:
    Kint\Parser\BlacklistPlugin::$shallow_blacklist[] = 'Psr\Container\ContainerInterface';
  • To change display theme, use Kint\Renderer\RichRenderer::$theme = 'theme.css';. You can pass the absolute path to a CSS file, or use one of the built in themes:
    • original.css (default)
    • solarized.css
    • solarized-dark.css
    • aante-light.css
  • Kint has keyboard shortcuts! When Kint is visible, press D on the keyboard and you will be able to traverse the tree with arrows, HJKL, and TAB keys - and expand/collapse nodes with SPACE or ENTER.
  • You can write plugins and wrapper functions to customize dump behavior!
  • Read the full documentation for more information

Authors

Jonathan Vollebregt (jnvsor)
Rokas Šleinius (raveren)

License

Licensed under the MIT License

Comments
  • Proper way to include Kint in CMS's?

    Proper way to include Kint in CMS's?

    I've placed the Kint folder in the root of my site (/home/mydomain/public_html/devtools/kint/Kint.class.php) so I can use it in whatever I'm working on.

    I've directly added the include_once in a basic PHP file and tested it, and it worked great. I also removed the include from the file and added it in php.ini under auto_prepend_file which also worked.

    However, whether I directly include or use auto_prepend in either one of my WordPress sites or Drupal sites, I just get a WSOD in either one of them. Even turning on error reporting via:

    ini_set('display_errors', 1);
    error_reporting(E_ALL|E_STRICT);
    

    to try and troubleshoot why it's not working, results in no errors shown or logged, just a WSOD. In fact, I would prefer to keep it always enabled in php.ini but since it breaks my CMS's I have to disable it there.

    Any suggestions?

    Thanks!

    opened by STaRDoGG 38
  • RFC: Major version bump - Kint 2.0-dev

    RFC: Major version bump - Kint 2.0-dev

    Today, I've pushed something to jnvsor/kint/2.x-dev. I've been working on this for about 3 months now, I've basically rewritten all of Kint from the ground up.

    I'd like this to be a starting point for a new major version of kint.

    Bugfixes

    #50 #175 #203 #197 #182 #177 #176 And probably more too...

    Plugins

    Lots of kint is very rigid. It's not designed with extensibility in mind. Most of the time you want to customize behaviour you have to edit kint source code yourself. In some of the best cases you have to dump new files inside kint's directory tree. These are bad things for anyone that wants to install an update.

    My branch has a very extensive plugin system, to the point where you can pretty much replace both the parsing and rendering systems entirely without ever touching kint source code. This makes it possible for user provided solutions to certain feature requests: #107 (High prio for over 2 years! :D) #185 #94 #189 #87 : No longer applies: All the config system did was set a few properties on the kint class, you can do that from anywhere and have an easier time of it and a cleaner codebase

    Additionally, because the parser/renderer/plugins etc are properly decoupled, it can be meaningfully unit tested. (This provides a start at #26)

    In fact, it's so decoupled that if you want you can just call the parser and renderer and leave the main Kint class out of the loop entirely. (TODO: Some plugins get hardcoded info from Kint class, max_str_length in Kint_Object_Blob for example)

    Internals

    Kint master internals are Lovecraftian - peer at them too long and your sanity will be devoured by the great old ones.

    Sarcasm aside - kint seems to have been developed very organically, which isn't necessarily bad but tends to add technical debt.

    • We have a parser that outputs HTML, so if you want a decorator that doesn't you first have to unparse the HTML (See 2db0845f7a9ac642d09947e6f000e57e3b91ac64 )
    • For some reason the parser is actually a child class of the data objects it's supposed to produce (???)
    • The parser tries valliantly (And fails miserably) to prevent recursion "ghosts" on referenced arrays at the root level (See #203, #204) I've explained why this can't be done before, but that's a complex topic so I'll leave that for the other issues.
    • Parser plugins almost exclusively produce html, so they're by definition reliant on the rich renderer. Checks on Kint::$enabledMode are strewn throught the parser system.
    • It's a deck of cards. Everything is far too tightly coupled.

    Long story short: I gutted everything. Now the parser just returns data, and the renderer takes that data and does whatever with it. The individual parts are all smaller: The rich renderer is 10% smaller, the parser is 40% smaller, the JS renderer (The example for the unparsing problem) is also 40% smaller.

    Lots of special case code has been moved from the parser and main kint class into plugins where they belong: Backtrace handling, tabular display, etc

    Basically it's a big-ass cleanup and for the most part easier to grep

    The catch

    Well not catch so much as caveats.

    This is a work in progress

    While it works fine for basic debugging, most of the plugins aren't ported yet. ClassStatics, ClassMethods, Microtime, Closure and Trace have all been ported, but there's still a small mountain worth of missing ones (Including things like the tabular display that used to be hardcoded in the parser)

    The plain renderer also hasn't been ported yet, so PLAIN WHITESPACE and CLI output modes won't work till that's done.

    It's got a lot of good stuff, but it's not feature parity (Yet)

    This is not a stable API

    I'm very happy with the way the parser works. I've put a lot of thought into it and it seems to work beautifully. The problem is the renderer.

    The renderer needs to know how to take data and turn it into output. Currently, the parser plugins can add a "Class" to a representation (Tab) and the renderer maps that class to a renderer plugin. This works fine but there's no way to alter the way a header is rendered, only a tab. I intend to make large changes to the plugin system until it's working well enough.

    Here be monsters.

    It's slow

    Last I checked the parser was some 1000% faster than the old parser, but the renderer is significantly slower and it all evens out at a 50% slowdown (Last I checked... I've changed a lot since then)

    I'm not actually sure why this is - when I stub out all the relevant functions so it's just outputting enough to let me know it's actually outputting at all, it's still far slower. I'm guessing it's some PHP internal optimization - probably something in static methods that PHP deems pure so it caches the result or some such.

    All that said, it's not too slow - I don't see any difference in normal use. The pliability benefits of the new plugin system outweigh a speed difference I can't tell exists without tools. I'll take a closer look after I'm satisfied with the API.

    It works in PHP 5.1

    While I'd like to make a smiley and say this is just a joke about kint's strict version requirements (next month 5.1 will have been EOL for a decade) the truth is it's so old I couldn't find a way to get it working so while it absolutely should work on 5.1 I have NO way of proving that. If anyone can test it for me (Or show me an easy way to do it myself) that would be a big help.

    The code style

    Code style conversations are always purely subjective. Subjective enough to turn into flame wars so I'm not going to bother rooting for the code style I use here, or against the code style in master.

    Instead I'm going to argue on consistency. Consistent code style is good right? We can agree on that right? Right?...

    Anyway, I'm not very consistent. I drift between K&R, PSR, trololol-minified-php-ftw, and generally don't have anything consistent enough to write my own code style rules. So I let my computer do it for me.

    php-cs-fixer guarantees consistent code. It also lets me write whatever sloppy nonsense I want to then fix it with a simple command. Because it's a program, we could also enforce it alongside a test suite with CI.

    There are other purported php formatters out there but of the few I've tried php-cs-fixer is the best (One of them actually changed method naming styles and broke a system on me once... Yay) and the defaults are fairly sane and PSR compliant. Most importantly, I personally can attest that if I stuck with master's code style I'd have been at it for another 3 months :)

    What needs to be done

    If anyone has any ideas that could clean up the architecture I've made here that would be great

    • I want to tweak the rendering system a bit so that plugins can effect headers as well as tabs, so I'll probably end up gutting that for the fifth time.
    • It needs to be tested for 5.1 compat
    • I need to find out what's going on with rendering performance. This should wait until all plugins are ported as that can effect performance too.
    • A lot of plugins need to be ported
    • A test suite would be nice, but lets get things working first.
    • I want to decouple a few things that shouldn't be in the main Kint class (max_str_length should probably be on the renderer not the Kint class, the Trace plugin should have a configurable alias tracking system, etc)
    opened by jnvsor 26
  • Deprecate blacklist/whitelist in favour of blocklist/allowlist

    Deprecate blacklist/whitelist in favour of blocklist/allowlist

    There's the $parser_plugin_whitelist and there's the BlacklistPlugin with quite some occurrences of these problematic strings. Of course also in the test. I guess we can't simply replace the one strings provided by PHPUnit but maybe let's start by providing alternatives for the ones we currently have in Kint and deprecate the old ones for now.

    opened by leymannx 25
  • Make kint minitrace more readable

    Make kint minitrace more readable

    use light-grey color (#ddd) makes the minitrace very difficult to read in almost all kint themes. The only theme in which use #ddd has sense is "solarized-dark"

    kint-minitrace

    opened by willzyx-dev 24
  • Issue on Windows console

    Issue on Windows console

    Calling s() from console works great in Linux, however in Windows it doesn't show the unicode table drawing characters correctly.

    I accept anything ranging between:
    a) disable these characters altogether,
    b) replace them with ordinary dashes and pipelines, or c) create a fix to show them correctly on Windows.

    opened by DRSDavidSoft 23
  • Error message: Cannot access non-public member

    Error message: Cannot access non-public member

    I get this error. As I noticed, this only applies to static private property

    An exception (ReflectionException) was thrown in phar://<ROOT>/wp-content/plugins/zu-plus/includes/debug/kint.phar/src/Parser/ClassStaticsPlugin.php on line 94 while executing Kint Parser Plugin "Kint\Parser\ClassStaticsPlugin". Error message: Cannot access non-public member zu_Plus::$zukit_root

    What could be the problem?

    opened by picasso 20
  • Recursion detection by reference

    Recursion detection by reference

    As discussed in https://github.com/kint-php/kint/issues/203 this is recursion tracking by reference. The array and object references are collected in a "register" and if they are encountered a second time, that is considered a recursion.

    One of the benefits of this approach is that arrays are never tainted with markers, and at any time a plugin can pick the parsed array variable as it is.

    I do use hashes to address the object references, but that's because it is faster that way instead of traversing the whole list of knownObjects.

    @jnvsor has some concerns about memory leaks and performance, and I'll be looking forward for ways how to test these cases. So far I've only done the examples from https://github.com/kint-php/kint/issues/203 and the ParserTest.php unit test, and both work OK.

    Structurally, the output of the recursions is the same as from var_dump(). Here's what I used to compare:

    <?php
    
    include 'vendor/autoload.php';
    
    $a = ["Array 1"];
    $b = ["Array 2"];
    $a[] = &$b;
    $b[] = &$a;
    
    !d($a);
    !d($b);
    
    var_dump($a);
    var_dump($b);
    
    $r = (object) ['a' => 23, 'b' => 45];
    $r->c =& $r;
    !d($r);
    
    var_dump($r);
    

    There is a screenshot of the output here

    opened by kktsvetkov 20
  • View data in CLI

    View data in CLI

    I have file tst.php

    require_once 'vendor/autoload.php';
    d([1, 2, 3]);
    

    run this file in cli with php-kint v3 2019-06-14_11-02-19

    and with php-kint v1 2019-06-14_11-05-48

    Why data displaying is not correct in php-kint v3?

    opened by loveorigami 20
  • Recursion bug - leaving marker in arrays in certain conditions

    Recursion bug - leaving marker in arrays in certain conditions

    Don't know why exactly but:

    $a = ["Array 1"];
    $b = ["Array 2"];
    $a[] = &$b;
    $b[] = &$a;
    
    d($a);
    d($b);
    

    This shows the marker in $a in the second call.

    I'm doing an experimental overhaul of the parser (It's looking good) so I'll probably come across more of these things.

    bug 
    opened by jnvsor 16
  • add option to collapse all children

    add option to collapse all children

    When you for instance have an array of objects, you don't always want to see the contents of the objects, just the headers.

    I imagine the icon to look like 3 horizontal lines

    opened by winkbrace 16
  • Bug ? Wut ?

    Bug ? Wut ?

    aaa

    // in private function _getAllItems($url)
    // from class Alienware extends \GiveMeSomeGoodNews\Core\Controller
    \Kint::dump( $items ); //
    var_dump( $items );
    // ...
    

    serialize()

    a:4:{i:0;a:4:{s:5:"title";s:48:"Magicka: Wizard Wars Alienware Robe Key Giveaway";s:4:"guid";s:40:"ddcafe286003d79e0083dc32234b88a874c68aba";s:11:"description";s:513:"Go down in a blaze of glory with this exclusive Alienware Arena key for the Alienated Speedster robe. At the cost of 100 HP, you'll gain a 4% speed boost to outmaneuver your enemies and claim victory over their burnt corpses. With amazing Steam reviews like this: 8 elements, loads of fun, and beautiful C-H-A-O-S! Seriously get this game ASAP-[Nii-Wizards] Bacitoto Why haven't you gotten your exclusive robe and joined the action yet? Additional batch of keys added! About Magicka: Wizard Wars: Mag...";s:7:"pubDate";s:10:"1411954938";}i:1;a:4:{s:5:"title";s:47:"Kill The Bad Guy 33 Steam Discount Key Giveaway";s:4:"guid";s:40:"c3af1d6c9caae31d9f3058d51cd90c6808f2d560";s:11:"description";s:502:"Locate the target, execute a brilliantly sadistic plan, and watch the end result with this 33% Steam Discount for Kill The Bad Guy. Serving justice is just the side effect. Executing a brilliant plan intent on inflicting brutal pain is the real objective in Kill The Bad Guy. About Kill The Bad Guy: Does everyone deserve a second chance? Can crimes ever be forgotten? Hiding behind the mask of the average man on the street, and furtively blending into the background, many war criminals, ex-Mafia...";s:7:"pubDate";s:10:"1411954938";}i:2;a:4:{s:5:"title";s:39:"Broforce 25 Steam Discount Key Giveaway";s:4:"guid";s:40:"a4f301e1f8fc8d3414c2be65cd23f658ed55bebc";s:11:"description";s:504:"Never has it been more fun to turn the rest of the world into your own personal Brodom. Unleash liberty and freedom onto the rest of the world with this 25% Steam discount for Broforce. Bro with others or all on your own as the world once again turns to Broforce to raise the world to Brocon 1. So, what are you waiting for, a Brovitation? About Broforce: When evil threatens the world, the world calls on Broforce - an under-funded, over-powered paramilitary organization dealing exclusively in exce...";s:7:"pubDate";s:10:"1411954938";}i:3;a:4:{s:5:"title";s:45:"Shadow Warrior 75 Steam Discount Key Giveaway";s:4:"guid";s:40:"1764699fa1773b09b3e2d79558784d6f05b559b0";s:11:"description";s:505:"Need to stop a demonic invasion? A combination of guns, katana, magic, and wit are your weapons. Take this 75% Steam discount code for Shadow Warrior and decide what combination of death you will bring to the hoards of invading demons. About Shadow Warrior: Shadow Warrior tells the offbeat tale of Zilla Enterprise’s corporate shogun, Lo Wang, who is ordered by his employer to track down and acquire a legendary blade known as the Nobitsura Kage. Forced into a timeless battle, Lo Wang learns of th...";s:7:"pubDate";s:10:"1411954938";}}
    
    opened by Glaived 15
  • Psalm false-positives

    Psalm false-positives

    Psalm has quite a few false positives, but most of them can be fixed with well positioned typehints (All of which are prefixed @psalm-X in code)

    Some of these issues can't be fixed with typehints, or are clear bugs in psalm that probably shouldn't be fixed with typehints. Because of these we can't make static analysis required in CI. For now this is just a "todo list" and not high priority, since the code still works without it.

    • vimeo/psalm#4509
    • vimeo/psalm#8603
    • vimeo/psalm#8719
    feature-request 
    opened by jnvsor 0
  • Some HTML errors

    Some HTML errors

    Hi,

    While working on a project and validating the HTML code of the page with the W3C Markup Validation Service, I noticed that the Kint library had some HTML errors:

    1

    Possible solution for the <style> tag error

    The <style> tag must be contained in the <head> tag. So we could add it dynamically through JavaScript.

    Context

    • PHP: v8.1.2
    • Kint: v5.0.1 (latest)
    • Browser: Google Chrome v107.0.5304.107
    • OS: Windows 10
    feature-request 
    opened by Bugophobia 2
Releases(5.0.1)
  • 5.0(Nov 22, 2022)

    Kint 5 supports PHP 7.1 and above

    • Added spl_object_id support for PHP 7.2 and above. This displays in the same way as var_dump, symfony/dump, and xdebug's var_dump
    • Support displaying readonly modifier on properties
    • Supports visibility modifiers on class constants
    • Several callfinder fixes and tests for PHP8+ features (First class callables, DNF types)
    • Bugfixes:
      • SerializePlugin: Behaved very erratically before
      • Shows uninitialized private parent properties
      • Various others (See git log)
    • Added typehints wherever possible. Static analysis with psalm showed room for improvement, leading to several new interfaces made to ensure consistent constructors for static calls to eg. createFromStatics()
    Source code(tar.gz)
    Source code(zip)
  • 4.2.0(Aug 27, 2022)

  • 4.1.1(Jan 2, 2022)

  • 4.1(Dec 31, 2021)

    • Supports setting nonce attributes on script and style tags for CSP through Kint\Renderer\RichRenderer::$js_nonce and Kint\Renderer\RichRenderer::$css_nonce
    • Detects VT100 support on windows CLI to enable UTF8 and color support. Older windows versions or versions below PHP 7.2 have been changed to plain ASCII decorations since the original hasn't been working well for a while
    Source code(tar.gz)
    Source code(zip)
  • 4.0(Dec 18, 2021)

    • The folder is now off by default and can be enabled via the existing setting
    • Much improved search functionality
    • The PSR-11 service container is shallow-blacklisted by default. This will vastly improve performance on most frameworks such as symfony & laravel by stopping recursive parsing at the DI container unless you dump it explicitly
    • TracePlugin now supports blacklisting stack frames from paths, such as your /vendor/ folder
    • Numeric arrays with more than 1000 items in them will only dump the first 50 recursively. You can disable or configure this with ArrayLimitPlugin
    • Supports PHP 8.1
    • Lots of little stuff

    Breaking changes

    • Minimum supported PHP version is now 5.6
    • Kint::$max_depth has been renamed Kint::$depth_limit to match internals
    • Kint\Renderer\RichRenderer::$object_plugins has been renamed $value_plugins
    • The Object namespace has been renamed Zval - So certain class statics will have been renamed (eg. Kint\Object\BlobObject::$char_encodings to Kint\Zval\BlobValue::$char_encodings)
    • d(1) special case has been removed (Didn't work in edge cases) Call Kint::trace() instead
    • For plugin development there have been a lot of internal changes
      • The whole Object namespace has been renamed Zval in anticipation of naming conflicts
      • parseDeep has been removed
    Source code(tar.gz)
    Source code(zip)
  • 3.3(Nov 23, 2019)

    • Fixes for PHP 7.4
    • Namespaced functions will now be normalized correctly
    • Colors are automatically disabled in windows in CliRenderer
    • If (for some reason) you have neither iconv nor mbstring available, Kint will just assume ASCII and hope for the best
    • Event handlers for click/keypress are now registered as capture so other events on the page won't override them

    I will be starting work on a new major version next. 3.x support will continue for bugfixes

    Source code(tar.gz)
    Source code(zip)
  • 3.2.2(May 3, 2019)

  • 3.2.1(Apr 30, 2019)

    • FsPathPlugin now works for windows paths too
    • ToStringPlugin is now opt-in because of misbehaving third party libraries that cause fatal errors in it
    • Fixed search when folder is disabled
    Source code(tar.gz)
    Source code(zip)
  • 3.2(Mar 21, 2019)

    • Callfinder now supports calling kint with a trailing comma in PHP 7.3
    • Callfinder now supports expression detection with PHP 7.4's upcoming ??= operator
    • MysqliPlugin: Fixed some connection failure edge cases that would produce warnings
    • Rich SourcePlugin: Line numbers are back, and paste accuracy bugs are fixed
    • Added a test shim to allow testing on PHP 7.4/8+
    • Removed ruby dependency for sass formatting/compilation
    Source code(tar.gz)
    Source code(zip)
  • 3.1(Feb 14, 2019)

    • Fix folders to work when loaded with ajax
    • RichRenderer: Allow dumps to be put into the folder individually
    • export-ignore phar file for sensitive IDEs
    • Added MysqliPlugin (Opt-in)
    Source code(tar.gz)
    Source code(zip)
  • 3.0(Oct 1, 2018)

    We're here!

    Kint 3 bumps the minimum requirement up to PHP 5.3, comes separately in a phar file, and now uses namespaces.

    The facade has been heavily rewritten to make it easier to reuse instances of Kint for performance.

    kint-php/kint-js and kint-php/kint-twig have been updated to match Kint 3, with kint-twig making heavy use of the new facade features

    The rich renderer now sends dumps to a folder docket at the bottom of your browser by default. You can turn this off with Kint\Renderer\RichRenderer::$folder = false if needed

    Source code(tar.gz)
    Source code(zip)
  • 3.0-alpha2(Jun 8, 2018)

  • 3.0-alpha1(May 18, 2018)

    The first tag of the new major version. This drops support for PHP 5.1/5.2, but improves code quality all around. A more or less full list of changes is available in issue #260

    Source code(tar.gz)
    Source code(zip)
  • 2.2(Sep 6, 2017)

    • Bugfixes
    • Added special access paths for some magic methods
    • Sort methods by line number after hierarchy
    • Sort properties with strnatcasecmp instead of strcmp
    • Added blacklist to ToString plugin, add SimpleXMLElement by default
    • Removed the value representation from unknown types
    • Removed object property reflection
    • Made some parser plugins opt-in:
      • Binary
      • Serialize
      • DOMNode/DOMIterator
    • Renderers can now alter parser plugins before parsing
      • The text-based renderers now disable all the plugins they don't use ahead of time
    • Added special access paths for more magic methods like __toString
    • Dropped automated testing of PHP 5.2
      • 5.2 will be dropped when TravisCI drops it in april
      • 5.1 and 5.2 are still technically supported, but since (hopefully) no-one uses those any huge bugs will be fixed on an as-reported basis.
    • Added Kint::dumpArray to allow you to supply your own object seeds (Names and access paths) along with an array of data. Useful for integrating with other systems.
      • This allows correct access paths for Kint::trace()
    Source code(tar.gz)
    Source code(zip)
  • 2.1.2(Jul 3, 2017)

    Most of this release is bugfixes, but there are a few notable changes.

    • Disabled the binary, DOMNode, DOMIterator, and Serialize plugins. They're still there but you have to opt-in now. For reasons behind these choices see #244
    • Max depth has been lowered to 6. Because Kint currently supplies much more information than v1 did it's also a bit slower. This is compounded by the constantly increasing interdependent hierarchies in use in modern PHP systems. Because the access paths are a thing in Kint 2 it's very easy to run a second dump to get deeper in, so this will barely make a dent for usability, but lowering the depth limit one level typically cuts runtime in 3!
    • There is now a parserPlugins method on the Kint_Renderer which can alter or supply a list of plugins for the parser to be initialized with. A whitelist on the text renderer makes use of this by disabling most of the plugins so text, cli, and plain dumps are fast.
    • Dropped reference detection support below 5.2.1. This had been causing infinite loops since alpha2 and no-one noticed. /me clumsily foreshadows impending PHP version requirement bump
    Source code(tar.gz)
    Source code(zip)
  • 2.1.1(Jun 20, 2017)

    • Bugfixed accidental write to input variables in Closure plugin

      This is a serious bug and the reason for the emergency patch release. This bug may affect operation of caller code in a default Kint 2.0+ installation. Please upgrade at your earliest convenience.

    • Removed value representation from unknown types

    • Stricter parsing and testing for "Impossible index" variables

    • Updated nodejs to use a lockfile

    Source code(tar.gz)
    Source code(zip)
  • 2.1(May 13, 2017)

    • Bugfixes
      • Missing "Inherited from" in docstrings
      • Renderers: Get return status from settings, not directly from modifiers
      • Sourceparser would explode on 5.1 and 5.2 (Since no-one brought that up it means we have pleasantly few people using those old versions)
      • Fixed a bug in certain browsers where tripleclick select all would add 4 spaces of indentation for some reason.
      • Fix bug in complex string parsing ("${var}" would add an extra indentation level, causing the var name/access path to go on until the end of the containing block)
      • Make the shorthand (d(1);) show a backtrace to the same depth as Kint::trace()
      • PHPUnit failed to check for certain error levels in certain circumstances
      • Fixed a bug in the way the trace plugin validated traces. (Let's just say it was completely wrong)
    • Added unit tests
      • Kint class
      • Kint_Parser_Trace plugin (Also used independently by helper for minitrace etc)
      • Kint_Object_Representation
      • Kint_Object
      • Kint_Object_Blob
      • And tweaks to parser, sourceparser tests
    • Representation names now contain digits when automatically transferred from labels
    • Added .gitattributes to clean up distributed archives and stop compiled files from messing up the diff view.
    • Character encodings now work slightly different
      • ASCII and UTF-8 are the only ones enabled by default now (Should be a bit of a performance boost)
      • Some investigation has lead me to believe that mb_detect_encoding only practically supports
        • ASCII
        • UTF-8
        • SJIS
        • EUC-JP
      • Windows-1252 is using some custom validation if mb_detect_encoding fails, since just about any byte is valid in 1252
      • Accordingly, the Binary plugin will always trigger if the string is not UTF-8 or ASCII
    • Blacklist '/' and '.' for FsPath plugin (Since those strings are likely to show up often)
    • Moved string escaping into renderers
      • Deprecates Kint_Object_Blob::escape and Kint_Renderer_Rich_Plugin::renderLockedHeader, to be removed in next major version.
    • Added Exception plugin (Shows message in bar)
    • Added DateTime plugin (Shows value in bar)
    • Added links to PHP documentation for internal functions and methods
    • Massive performance improvement to the sourceparser. The base call time of Kint was a bit slow on very large files
    • Source code is gzcompressed in the built files, then gzuncompressed and evalled at runtime. This brings the file size down to under 40kb
    Source code(tar.gz)
    Source code(zip)
  • 2.0(Apr 22, 2017)

    Hooray! After more than 18 months and more than 230 commits, Kint 2.0 is here!

    This is a ground-up rewrite of most of the Kint functionality. There are a lot of new features, so I'll summarize the big differences from 1.1:

    • Access paths - Automatically see the code you need to get somewhere deep in the hierarchy
    • Frontend usability tweaks - Clicking on the [+] once will only unfold one level. Keyboard and mouse control can be used at the same time
    • Single file distribution: All of Kint in a single file. Download and include and you're done
    • Much better plugability: You can alter pretty much all of Kint's behaviour without touching the Kint source code
    • Blacklist plugin: Skip overweight classes to make Kint dumps faster
    • Lots of bugfixes
    • Cleaner code
    • Unit tests
    • Can be used as a library
    • Easier build process
    Source code(tar.gz)
    Source code(zip)
  • 2.0-rc1(Apr 22, 2017)

    • Smaller single file generation
    • Obfuscated openInNewWindow to stop malicious actors (Like anti-virus) from injecting html halfway through our JS
    Source code(tar.gz)
    Source code(zip)
  • 2.0-beta2(Apr 19, 2017)

    • Adds single-file compilation! Now you can just download a single file and include it and hurray you're up and running!
      • Separate files for separate themes
    Source code(tar.gz)
    Source code(zip)
  • 2.0-beta1(Apr 15, 2017)

    • Renderer properties are protected not private to make renderer extending easier
    • A few bugfixes
    • A new source code parser that's a bit more robust than the preg_match black magic. Allows for access paths when the source file can't be parsed too
    • Since I don't plan on making any more large structural changes, this is the first beta release of 2.0. Breaking changes may still occur, but infrequently.
    Source code(tar.gz)
    Source code(zip)
  • 2.0-alpha5(Apr 14, 2017)

    • Composer setting extra.kint.disable-helper-functions allows conflicting packages and the root composer.json to disable the helper functions and use Kint purely as a library
    • A few bugfixes
    Source code(tar.gz)
    Source code(zip)
  • 2.0-alpha4(Apr 9, 2017)

    • Update NPM dependencies and mark it private to stop whining about repository info
    • Added build status to readme
    • Lots of bugfixes
    • Added PHPUnit and full testing of Kint_Parser
    • Improved performance in the rich renderer by caching method headers
    • Added Kint_Parser_Blacklist::$shallow_blacklist to blacklist objects except when they're dumped directly
    • 2.x is now the master branch. The 1.1+ versions are in the 1.x branch
    Source code(tar.gz)
    Source code(zip)
  • 2.0-alpha3(Mar 31, 2017)

    • Bugfixes
    • ToString plugin
    • Wrap plugins in a try-catch so that third party plugins don't leave user data in an unclean state if they explode
    Source code(tar.gz)
    Source code(zip)
  • 2.0-alpha2(Mar 26, 2017)

    • TravisCI support (Have to wait on @raveren to enable it on the repo, using one connected to my fork manually for the time being)
    • [+] icon now only opens one level by default. It seems like it was too hard to learn to click just about anywhere else so now it behaves like the rest of the bar. To open all descendants, doubleclick on the icon. To open all kint dumps on the page, tripleclick on the icon.
    • Text renderer: Added option to render without decorations
    • Rewrite parser plugin system. Now instead of a big static array full of classnames, the parser takes plugin instances through a method making it far better architecture. I also added a few mandatory methods to the plugins themselves to indicate which data types and parse stages they should use. This made for a huge performance boost and simplified some code (Removes the Kint_Parser_Plugin::parseChildren() method since the new methods achieve the same with less overhead)
    • Now detects and displays references (With the exception of the toplevel objects)
    • Now provides correct access paths for numeric string indexes in arrays, and integer properties in objects (Though these are read-only since PHP does some trippy stuff with them on assign)
    • Various bugfixes
    Source code(tar.gz)
    Source code(zip)
  • 2.0-alpha1(Mar 9, 2017)

    This is the first alpha for the rewrite of Kint into 2.0. It's nearly 200 commits and a year and a half of work, but as the tag says: Alpha.

    Feedback welcome - breaking API change suggestions should be accepted until beta at least

    Source code(tar.gz)
    Source code(zip)
  • 1.1(Mar 9, 2017)

  • 1.0.10(Sep 16, 2015)

A simple Craft module, inspired by Mildly Geeky's "Kint", to debug Twig within your browser

A simple Craft module, inspired by Mildly Geeky's "Kint", to debug Twig within your browser

TrendyMinds 4 Feb 2, 2022
The ultimate debugging and development tool for ProcessWire

Tracy Debugger for ProcessWire The ultimate “swiss army knife” debugging and development tool for the ProcessWire CMF/CMS Integrates and extends Nette

Adrian Jones 80 Oct 5, 2022
Xdebug — Step Debugger and Debugging Aid for PHP

Xdebug Xdebug is a debugging tool for PHP. It provides step-debugging and a whole range of development aids, such as stack traces, a code profiler, fe

Xdebug 2.8k Jan 3, 2023
Buggregator is a beautiful, lightweight web server built on Laravel and VueJs that helps debugging your app.

A server for debugging more than just Laravel applications. Buggregator is a beautiful, lightweight web server built on Laravel and VueJs that helps d

Buggregator 311 Jan 4, 2023
A collection of helper methods for testing and debugging API endpoints.

Laravel API Test Helpers This is a collection of helper methods for testing and debugging API endpoints. Installation You can install the package via

Stephen Jude 49 Jul 26, 2022
Sage - Insightful PHP debugging assistant ☯

Sage - Insightful PHP debugging assistant ☯ At first glance Sage is just a pretty replacement for var_dump() and debug_backtrace(). However, it's much

null 27 Dec 26, 2022
WordPress debugging made simple.

Loginator Debugging WordPress can sometimes be a pain, our goal is to make it easy, which is why Loginator was built with this in mind. From creating

Poly Plugins 2 Feb 12, 2022
A tool to profile mysql queries in php env.

MysqlQueryProfiler This tool helps you to quickly profile a mysql query in a PHP 7.4+ environnement. You can also compare 2 queries. This image shows

null 8 Jul 30, 2021
This package connects a Laravel Octance application with Tideways for PHP Monitoring, Profiling and Exception Tracking.

Tideways Middleware for Laravel Octane This package connects a Laravel Octance application with Tideways for PHP Monitoring, Profiling and Exception T

Tideways 7 Jan 6, 2022
Handle PHP errors, dump variables, execute PHP code remotely in Google Chrome

PHP Console server library PHP Console allows you to handle PHP errors & exceptions, dump variables, execute PHP code remotely and many other things u

Sergey 1.4k Dec 25, 2022
PHP APM (Alternative PHP Monitor)

APM (Alternative PHP Monitor) APM (Alternative PHP Monitor) is a monitoring extension enabling native Application Performance Management (APM) for PHP

Patrick Allaert 310 Dec 4, 2022
Zipkin PHP is the official PHP Tracer implementation for Zipkin

Zipkin PHP is the official PHP Tracer implementation for Zipkin, supported by the OpenZipkin community. Installation composer require openz

Open Zipkin 250 Nov 12, 2022
Laravel Dumper - Improve the default output of dump() and dd() in Laravel projects

Laravel Dumper Improve the default output of dump() and dd() in Laravel projects. Improves the default dump behavior for many core Laravel objects, in

Galahad 301 Dec 26, 2022
Debug bar for PHP

PHP Debug Bar Displays a debug bar in the browser with information from php. No more var_dump() in your code! Features: Generic debug bar Easy to inte

Maxime Bouroumeau-Fuseau 4k Jan 8, 2023
PHP Benchmarking framework

PHPBench is a benchmark runner for PHP analogous to PHPUnit but for performance rather than correctness. Features include: Revolutions: Repeat your co

PHPBench 1.7k Jan 2, 2023
The Interactive PHP Debugger

The interactive PHP debugger Implemented as a SAPI module, phpdbg can exert complete control over the environment without impacting the functionality

Joe Watkins 841 Oct 9, 2022
Dontbug is a reverse debugger for PHP

Dontbug Debugger Dontbug is a reverse debugger (aka time travel debugger) for PHP. It allows you to record the execution of PHP scripts (in command li

Sidharth Kshatriya 709 Dec 30, 2022
PHP Debug Console

PHP Console A web console to try your PHP code into Creating a test file or using php's interactive mode can be a bit cumbersome to try random php sni

Jordi Boggiano 523 Nov 7, 2022
Php Debugger to run in terminal to debug your code easily.

What is Dephpugger? Dephpugger (read depugger) is an open source lib to make a debug in php direct in terminal, without necessary configure an IDE. Th

Renato Cassino 190 Dec 3, 2022