Releases: molsonkiko/JsonToolsNppPlugin
Releases · molsonkiko/JsonToolsNppPlugin
v8.5: Allow parsing of ANSI documents, improve error form, various bug fixes
[8.5.0] - 2026-03-04
Added
- New
Make this visibleoption on the tree view's right click context menu to reveal nodes hidden by code folding. This was first requested in issue 103.
Fixed
- Correctly parse all ANSI files. Previously JsonTools assumed that Notepad++ used UTF8 to internally represent every document, and while that appears to have worked fine for most encodings, it would specifically fail on ANSI-encoded documents containing non-ASCII.
- The following features are currently still broken on ANSI files with non-ASCII characters (because they rely on knowing the position of a JSON node):
- Minor bug where JsonTools could not set the text of a file to end with the SOH character (ASCII code
\x01) - Minor bug where some JsonGrepper tests would always fail because they queried an external API that had previously returned JSON but now returns HTML.
- Bug where editing a document in multi-selection mode would sometimes cause selections to be forgotten (fixed in v8.4.0.3)
- Bug (issue 104) where error form would not always re-parse the document after the
Refresh with current errorsright-click context menu item on the error form was clicked. - Bug where
s_joinRemesPath function would not throw an exception when the second argument was an array containing non-strings (previously it would silently treat nulls, objects and arrays as though they were empty strings).
v8.4.0.4: alternate version allowing arbitrarily large integers
[8.4.0.4] - 2025-07-24
WARNING: Although this version of JsonTools is more recent than v8.4, it has significantly worse performance. Do not update to this version of JsonTools unless you expect to be parsing integers larger than 9223372036854775808 or lower than -9223372036854775807.
Changed
- Internally represent integers as BigIntegers instead of 64-bit integers, meaning that JsonTools can correctly parse integers of unlimited size.
v8.4: Add translation to more languages, allow disabling keyboard shortcuts
[8.4.0] - 2025-05-04
Added
- Add
recurse_untilRemesPath function to recursively search arrays and objects for anything inside that satisfies a condition. - Add
keyboard_shortcutssetting, allowing users to turn off default JsonTools keyboard shortcuts. - Courtesy of user hydy100, Translation to Arabic, Chinese (simplified), French, German, Japanese, Korean, and Taiwanese Mandarin.
Fixed
- Mostly fix bug where icons would disappear when going from light to dark mode. As a side effect, the icons when using "standard icons: small" are smaller, but the icons under other conditions are larger.
- Fix intermittent crash during UI tests in 64-bit Notepad++ by eliminating reference to the dangerous
NPPM_GETOPENFILENAMESmessage.
v8.3.1: Fix crash with empty RemesPath queries; properly raise error for more bad RemesPath queries
[8.3.1] - 2024-12-22
Fixed
- Fixed bug where running a RemesPath query in the tree view would cause a crash if the query box was empty or contained only whitespace.
- Fixed bug where some errors would not be raised on some syntactically invalid RemesPath queries containing two valid items not separated by a binary operator. For example,
1 * -2 7andbar + @[0] 9both had this problem.
v8.3: *fully fix* decimal formatting, allow parse \u0000 and \x00, minor improvements
[8.3.0] - 2024-12-22
Changed
- Use a different algorithm for representing decimal numbers to fix issues 83 and 81 on computers where v8.2 had not fixed those issues.
- As an unfortunate consequence of this fix, a very very small percentage of very high-precision decimal numbers will lose precision using this new algorithm. The vast majority of numbers with 17 digits of precision (the maximum precision attainable by JsonTools) will not lose precision when reformatted by JsonTools. For example, JsonTools will pretty-print
-6553693.3617752995as the lower-precision-6553693.3617753. However, note that JsonTools still handles high-precision doubles better than the JSON-Viewer plugin.
- As an unfortunate consequence of this fix, a very very small percentage of very high-precision decimal numbers will lose precision using this new algorithm. The vast majority of numbers with 17 digits of precision (the maximum precision attainable by JsonTools) will not lose precision when reformatted by JsonTools. For example, JsonTools will pretty-print
- Automatic parsing after editing and automatic JSON schema validation on opening a file no longer makes the error form visible if the user had previously opened the error form and then hid it.
- Tree view icon and menu item check are now correctly toggled depending on whether a tree view (other than the grepper form's tree view) is visible. This doesn't matter much, since multiple tree views can be open and a tree view that is not visible could become visible again, but it is a nice visual cue.
Fixed
- When a file is pretty-printed or compressed or edited with RemesPath, the caret will be scrolled into view. Previously, if the file contained very long lines and word wrapping was turned off, the user might have to manually scroll to the left after pretty-printing or compressing.
- NUL characters (when rendered as
\u0000or\x00) can now be parsed. Previously they raised a fatal error.
v8.2: fix decimal formatting, rename tree views, many bugfixes
[8.2.0] - 2024-11-09
Added
- When a file is renamed, the name of a tree view associated with that file also changes to match the new name. This also happens when a treeview is refreshed with JSON from a different file.
- Add
rand_schemaRemesPath function to generate random JSON from schema.
Changed
- If a number string is too large or small for a 64-bit floating point number (for example,
-2e700,3.5e+450), the JSON parser will now represent them as-Infinity(if they have a leading-sign) orInfinity, rather than representing them asNaN. The linter also has a new message for when this happens. - If a JSON lines document is not compliant with the strict JSON specification, the status bar will now reflect that it is JSON lines.
- Stop considering the user's Windows culture when determining the UI language for JsonTools (fix issue 82). Now JsonTools will be translated into language X if and only if Notepad++ is in language X.
Fixed
- Fix issue (introduced in v8.1, see issues 83 and 81) where decimal numbers were given unnecessarily precise string representations. For example, in JsonTools v8.1,
11.11would be represented as11.109999999999999even though the original11.11was an equally valid representation. Now all decimal numbers will be given the more compact representation used in v8.0 and earlier unless the more verbose representation introduced in v8.1 would be necessary to avoid loss of precision (so there will be no regression on issue 78). Note that this new algorithm for formatting decimal numbers is about twice as slow as the algorithm used in v8.1 (for 64-bit JsonTools; 32-bit has no performance loss), although the impact on performance will be much less dramatic unless you are compressing an array where almost every element is a non-integer decimal number. - Fix the following issues with random string from regex:
- It previously incorrectly flagged some valid regular expressions (e.g.
(?-i)(?:xy{1,2}){,2}) as having two consecutive quantifiers. - It previously did not correctly handle some character sets where the final character was
-(for example,[+-]previously would only generate+, and now it correctly has a 50% chance of generating-or+)
- It previously incorrectly flagged some valid regular expressions (e.g.
- Fix issue where RemesPath incorrectly inferred the type of (a function
funfollowed by indexers) to be the return type offun. For example, running the querysum(dict(items(@)).a)on the JSON{"a": [1]}now correctly returns1.0, but RemesPath used to raise an error because it assumed thatdict(items(@)).ahad the same type asdict(items(@)) - Fix very rare crash bug when using the
Value to clipboardoption of the tree node right-click context menu. - Fix bug where some invalid JSON Lines documents (for example,
[1, \n2][3]) would be accepted by the JSON Lines parser despite having elements that span multiple lines. - Fix minor bugs with how headers are formatted in the
s_csvRemesPath function and JSON-to-CSV form. - Fix bug where renaming a file subject to schema validation based on filename patterns would cause its tree view to be lost.
- Fix bug where plugin actions (mainly RemesPath queries in regex mode) that set the text of the entire document to an empty string would not do anything. Those actions will now correctly remove all the text in the document.
- Fix issue 79 where, on higher display resolutions than the default 125% normally used by molsonkiko in development, some of the advanced controls in the find/replace form would not be visible.
- Fix annoying but harmless bug where, if the user had two views open and ran a plugin command on one or more selections in the second view, the indicator that JsonTools uses to remember selections (which is supposed to be hidden at all times) would cause the selections to be underlined.
- Address issue 80; now error form will be cleared of errors when the JSON parser does not log any syntax errors.
- Make it so that JSON Lines documents are correctly formatted as JSON Lines after sorting by the sort form.
- Make it so that refreshing a tree view originally associated with
oldFilewith JSON fromnewFilewill correctly cause the tree view to be associated withnewFile. Previously, the tree view stayed associated witholdFile, so attempting to open a new tree view foroldFilewould instead close the tree view now associated withnewFile, because the command to open a tree view for a file closes that file's tree view if it already has an open one.
v8.1: improve "JSON from Files and APIs" form; improve translations; random string from regex; fix many bugs
[8.1.0] - 2024-08-23
Added
- Progress reporting with the JSON from files and APIs form (henceforth the
grepper form). - In the
grepper form, pressingEnterinside thePreviously viewed directories...box causes the current text of the box to be searched, assuming that it is a valid directory. - Translation of the following:
- Settings in the Settings form.
- JSON syntax errors and JSON schema validation errors (under the
jsonLintfield of the translation file) - Generic Windows message boxes (the boxes with
Ok,Yes,No, andCancelbuttons and no other controls).
- The
path_separatorsetting for formatting keys/indices and paths. Addresses issue 69. - Make it so left-clicking on the
Key/index to clipboardandPath to clipboardoptions of the treenode right-click context menu gets the path or key/index in whatever the default is from your settings, without having to click on one of the sub-menu items. - The
grepper formnow supports\and/(path separators) in search patterns, as well as**to match any number of characters (including\). - Generation of random strings from regular expressions.
- The
grepper formnow reads and parses all files asynchronously, and can be canceled. - While the
grepper formis working on a request, it now ignores clicks on the API request button and the Search directories button.
Changed
- Rename
Choose schemas to automatically validate filename patternstoValidate files with JSON schema if name matches pattern, in the hopes that the new name will be less confusing. - Changed the wording of many JSON syntax error messages to be more consistent, per conky77's suggestion here.
- When attempting to translate to other languages, JsonTools now checks the UI language of Notepad++ before checking the Windows UI culture.
- When automatic validation after editing is turned on, only modifications that change the text of the document will trigger re-parsing.
Fixed
- If there would be an
OutOfMemoryExceptiondue to running out of memory while formatting JSON (a likely occurrence when using thegrepper form), that error is caught and reported with a message box, rather than potentially causing Notepad++ to crash. - Ensure that hitting the down key does nothing when the last row of the error form is selected.
- Fix bug with random json from schema when parsing a schema that has the
enumkey but not thetypekey. - Make it so JsonTools simply does nothing rather than causing Notepad++ to crash when attempting to run plugin commands on files with more than 2147483647 bytes.
- Fixed number precision bug (issue 78).
- Rare bug generating schemas from JSON, only seen with some arrays of objects.
- Rare crash when saving
schemasToFnamePatterns.jsonif automatic validation after editing is enabled. - Changes to the
max_schema_validation_problemssetting will apply immediately, including to previously compiled JSON schemas. - Unrecoverable crash due to stack overflow when generating random JSON from a recursive schema.
v8.0: add translation to other languages; improve tree view UI; remove some minor settings
[8.0.0] - 2024-06-29
Added
- Made it possible to translate JsonTools into other languages.
- Made the tree view font size configurable with the
tree_view_font_sizesetting. Fixes issue 66. - Added dark mode tree view icons (addresses this GH issue comment).
- Allow users to manually enter directory names in the JSON from files and APIs form (referred to as "grepper form" for the rest of this section) rather than using a dialog or the dropdown menu.
- Added a "Search directories" button to the grepper form.
Changed
- Removed the
max_threads_parsingsetting for the grepper form, because the underlying implementation was changed in a way that made that setting useless. - Removed the
allow_datetimessetting, because I do not feel confident that the potential benefits of the setting outweigh the danger of accidentally changing the format of people's dates or datetimes in some way that they were not expecting. - When all files have been parsed in the directory chosen with the grepper form, the directory name is no longer reset to the default value.
- Added a hard limit to the total combined size of all files parsed by the grepper form, to avoid hitting memory errors.
Fixed
- Avoid unnecessarily refreshing the styles of all forms when settings other than
use_npp_stylingortree_view_font_sizeare changed. - The list of recently chosen directories in the grepper form is pre-filtered for existing directories, to hide the partial directory names that contaminate the config file.
- Fix bug where, if a setting in the config file had an invalid value (for example, a numeric setting having a value of
blah), there might be an uncaught exception that would cause Notepad++ to crash. This bug appeared to be most likely to occur when the localization is not set toen-us.
v7.2: fix various bugs; add "Check JSON syntax now" command
[7.2.0] - 2024-04-19
Added
Changed
- Made it so that reloading the error form by pressing
Enterwould not cause certain message boxes to appear, to eliminate a potential "infinite" loop where the user would hitEnterto close the message box, and that moved focus back to the error form, which then repeated the cycle when they lifted theEnterkey. - Automatic validation when
auto_validateis true no longer opens the prompt asking if user wants to open the error form (ifoffer_to_show_lintis true), because that could cause Notepad++ to crash or hang forever (see issue 60). - Made it so that automatic JSON schema validation (that is, any validation not manually invoked by the plugin menu command) no longer causes the caret to move to the location of the first schema validation error.
- Automatic validation (including non-schema validation) now refreshes the error form.
Fixed
- Minor bug in PPrint remembering comments algorithm implementation that caused some arrays and objects to be compressed when they should have been pretty-printed.
- Fix bug where tests could crash under some circumstances due to filesystem weirdness making it impossible to find test files.
v7.1: improve selection-based mode, fix issues with Notepad++ 8.6.5+, fix many other bugs
Added
minLengthandmaxLengthkeywords are now considered when making random JSON from schema- JsonTools now automatically navigates to the location of the fatal error when it fails to parse a document, unless the attempted parse was auto-triggered (say, by the automatic parse after editing)
- Selection-based mode now supports any number of remembered selections, and undo and redo actions usually do not cause selections to be forgotten. Performance also appears to be better.
Changed
- If the location of an error is between the
CRand theLFof aCR LFnewline, JsonTools will now always move before theCR, rather than placing the caret in between them, which could cause confusion. - Automatic JSON schema validation after editing does not happen when the document is in
REGEXmode. - Removed the
max_tracked_json_selectionssetting, as it is no longer necessary.
Fixed
- Using the Notepad++ find/replace form in Notepad++ versions 8.6.3 and 8.6.4 now appropriately shifts remembered selections when in selection-based mode.
- Bug where the space key did not work on the regex search form.
- Bug where automatic JSON schema validation after editing sometimes caused a deadlock that disabled some functionalities until Notepad++ closed.
- Possible plugin crash due to index-out-of-bounds error during parsing of JSON Lines.