Skip to content

Ctags json output is wrongly formatted #3305

Closed
@NimaAgm

Description

The name of the parser:C-parser

The command line you used to run ctags:
ctags.exe -R --languages=C --sort=yes -x --kinds-C=* --file-scope=yes --output-format=json -f tag2.txt

The version of ctags:

ctags --version
Universal Ctags 5.9.0(p5.9.20220306.0), Copyright (C) 2015-2022 Universal Ctags Team
Universal Ctags is derived from Exuberant Ctags.
Exuberant Ctags 5.8, Copyright (C) 1996-2009 Darren Hiebert
Compiled: Mar 6 2022, 01:06:23
URL: https://ctags.io/
Optional compiled features: +win32, +wildcards, +regex, +gnulib_regex, +internal-sort, +unix-path-separator, +iconv, +option-directory, +xpath, +json, +interactive, +yaml, +case-insensitive-filenames, +packcc, +optscript, +pcre2

the problem is the format of output json file is wrong and I cant not work with in python it says the formats is wrong and and I checked format in json format checker it was wrong

sample of json output
jsontags.txt

python error
raise JSONDecodeError("Extra data", s, end)
json.decoder.JSONDecodeError: Extra data: line 2 column 1 (char 93)

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions