-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WARN Error parsing JSON at .json #79
Comments
@eidswe That's interesting at least, when i try to search for "7z" -
|
Run https://github.com/PowerShell/PowerShell/releases/tag/v7.3.1 So you can choose this or if that doesn't work try this - both of the links above are from the official Microsoft PowerShell repository. Please report back about the results.. |
@anderlli0053 After installing PowerShell 7.3.0, the output of the search result remains unchanged, but the error message changes. The output is as follows: PowerShell 7.3.0 Name Version Source Binaries 7zip-aoks 22.01 DEV-Tools Installed PowerShell 7.3.1 instead, uninstalled scoop and reinstalled, error message unchanged. |
@eidswe Thanks for reporting back, There must be something wrong with your Scoop installation, as the buckets don't have no direct impact on Scoop files, i really don't see what and how is this connected to my bucket repository in any way, As i can see that error is caused by the Scoop script on the line 30 --> C:\Users\eidswe\scoop\apps\scoop\current\libexec\scoop-search.ps1:30 which is the function about "bin-ing" the executables. --> The script defines a function called "bin_match" that takes two parameters, "$manifest" and "$query". It first checks if the "$manifest" object has a "bin" property, and if not, it returns $false. If it does, it creates an array called "$bins" that iterates through each object in the "bin" property and performs several operations on each one. It assigns variables "$exe", "$alias", and "$args" to the current object in the iteration, and assigns the name of the file (without the path) to the variable "$fname" using the "Split-Path" cmdlet. Then it checks if the name of the file without the extension match the "$query" using the "strip_ext" function and the "-match" operator. If it matches, it adds the "$fname" to the "$bins" array. If the "$alias" matches the "$query", it adds the "$alias" to the "$bins" array. After the iteration is complete, if "$bins" array is not empty, it returns the "$bins" array, otherwise it returns $false. Try to write this into the console If you continue with the forementioned uninstallation and reinstallation of the Scoop you will also lose all your programs that you have installed, so i suggest that you create a backup manifest file with the command: To reinstall the Scoop run That JSON file is located on your Desktop and it stores the information about all the apps and the buckets that they come from, so when you reinstall the Scoop (if you choose so) you do not need to install every single app - one-by-one again. When you did re-installed it, after you uninstalled it successfully, open the newer PowerShell again and type the following to restore the apps from the previously created backup file:
After the Scoop finishes with the said import and installation processes you can run |
I have also checked and re-checked my whole bucket repo again with all the possible tools, from the linters to syntaxers and none find anything worth of the error(s). So i am pretty sure that you Scoop installation is corrupted, meaning that either some Scoop files are missing or they are unreadable or overwritten and therefore corrupted. |
@anderlli0053 |
this is what i asked scoop bucket rm dev-tools
|
@dong-lufei |
https://github.com/anderlli0053/DEV-tools What file or syntax of this bucket causes scoop search to report red, hopefully can be solved. Although scoop search can find the app results, it will report red before finding, and the search speed is slow |
II'll take a closer look into this; to try and figure out what's causing this, as all the tools for the bucket checkup report that is nothing wrong.. but there apparently is, since both of you @dong-lufei and @eidswe reported basically the same thing/issue |
also... does this happen for the manifests in "bucket" directory/folder only or also in other dirs of this repo? |
For the life of me i cannot replicate any error , that is on 3 different computers running Windows 10 and 11... AKA Files listed here appear to be OK:
|
@dong-lufei @eidswe Can y'all confirm if the issue(s) persist? |
@anderlli0053 The current problem is as follows: PowerShell 7.3.1 Name Version Source Binaries 7zip-aoks 22.01 DEV-Tools When I use scoop-search: PowerShell 7.3.1 'extras' bucket: 'main' bucket: 'seumsc_scoop-seu' bucket: 'versions' bucket: |
@anderlli0053 , the cause of the issue is the comments in the app manifest JSONs that are mentioned in the error output (duplicati, gcc etc.). No idea why it causes problems for some and not for others, but if you remove the comments from the JSONs - or use another way to include the information in the JSON - the issue disappears. |
Do these files still have this problem??
any new manifest that has this too?? |
The same problem was encountered.
In addition, when updating applications in this bucket, the following problems are encountered:
It is not clear if the two are related. |
Bug Report
duplicati-client.json.
[email protected]+x32.json.
[email protected]+x32.json.
[email protected]+x32.json.
[email protected]+x32.json.
[email protected]+x32.json.
[email protected]+x32.json.
groff.json.
[email protected].
[email protected].
mpc-hc-portable.json.
[email protected].
[email protected]+gcc.json.
[email protected]+gcc.json.
[email protected]+gcc.json.
[email protected]+gcc.json.
[email protected].
[email protected].
[email protected].
[email protected].
[email protected].
[email protected].
[email protected].
[email protected].
[email protected].
[email protected].
resourceHacker.json.
[email protected].
rsync.json.
[email protected].
[email protected].
UltraSearch.json.
[email protected].
wps-office-2016-lite.json.
Current Behaviour
After adding this bucket, when using scoop to search for software, the search is slow and an error is reported. The error message is as follows:
PS C:\Users\eidswe> scoop search 7z
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket.dprint.json.
Split-Path : 无法将参数绑定到参数“Path”,因为该参数是空值。
所在位置 C:\Users\eidswe\scoop\apps\scoop\current\libexec\scoop-search.ps1:30 字符: 29
$fname = Split-Path $exe -Leaf -ErrorAction Stop
~~~~
CategoryInfo : InvalidData: (:) [Split-Path],ParameterBindingValidationException
FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.SplitPathCo
mmand
Split-Path : 无法将参数绑定到参数“Path”,因为该参数是空值。
所在位置 C:\Users\eidswe\scoop\apps\scoop\current\libexec\scoop-search.ps1:30 字符: 29
$fname = Split-Path $exe -Leaf -ErrorAction Stop
~~~~
CategoryInfo : InvalidData: (:) [Split-Path],ParameterBindingValidationException
FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.SplitPathCo
mmand
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\duplicati-client.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+x32.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+x32.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+x32.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+x32.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+x32.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+x32.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\groff.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\mpc-hc-portable.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+gcc.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+gcc.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+gcc.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected]+gcc.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\resourceHacker.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\rsync.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\UltraSearch.json.
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\[email protected].
WARN Error parsing JSON at C:\Users\eidswe\scoop\buckets\DEV-Tools\bucket\wps-office-2016-lite.json.
Split-Path : 无法将参数绑定到参数“Path”,因为该参数是空值。
所在位置 C:\Users\eidswe\scoop\apps\scoop\current\libexec\scoop-search.ps1:30 字符: 29
$fname = Split-Path $exe -Leaf -ErrorAction Stop
~~~~
CategoryInfo : InvalidData: (:) [Split-Path],ParameterBindingValidationException
FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.SplitPathCo
mmand
Split-Path : 无法将参数绑定到参数“Path”,因为该参数是空值。
所在位置 C:\Users\eidswe\scoop\apps\scoop\current\libexec\scoop-search.ps1:30 字符: 29
$fname = Split-Path $exe -Leaf -ErrorAction Stop
~~~~
CategoryInfo : InvalidData: (:) [Split-Path],ParameterBindingValidationException
FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.SplitPathCo
mmand
Results from local buckets...
Name Version Source Binaries
7zip-aoks 22.01 DEV-Tools
7zip-beta 22.01 DEV-Tools
7zip-extra 2201 DEV-Tools
7Zip-Install 22.01 DEV-Tools
7zip-lzma 2201 DEV-Tools
7zip-nsis 22.01 DEV-Tools
7zip-zs 21.03-v1.5.0-R2 DEV-Tools
7zip-zstd-sdu 21.03-v1.5.0-R2 DEV-Tools
7zip-zstd v21.03-v1.5.0-R2 DEV-Tools
7zip 22.01 DEV-Tools
7zip19.00-helper 19.00 DEV-Tools
[email protected] 16.04 DEV-Tools
[email protected] 18.05 DEV-Tools
[email protected] 19.00 DEV-Tools
[email protected]+zs 21.02+zs DEV-Tools
[email protected]+zs 21.03+zs DEV-Tools
[email protected] 9.38 DEV-Tools
7ZipBeta-Portable 22.01 DEV-Tools
7ztm 2.1.1 DEV-Tools
asar7z 1.4 DEV-Tools
modern7z-aoks 1.8.10 DEV-Tools
modern7z 1.8.10 DEV-Tools
nanazip-portable 2.0.450 DEV-Tools 7z | 7zG
nanazip 2.0.450 DEV-Tools 7z | 7zG
7ztm 2.1.1 extras
asar7z 1.4 extras
7zip 22.01 main
7zip19.00-helper 19.00 main
modern7z 1.8.10 main
nanazip 2.0.450 main 7z | 7zG
7ztm 2.1.1 seumsc_scoop-seu
7zip-beta 22.01 versions
7zip-zstd v21.03-v1.5.0-R2 versions
Expected Behaviour
PS C:\Users\eidswe> scoop search 7z
Results from local buckets...
Name Version Source Binaries
7ztm 2.1.1 extras
asar7z 1.4 extras
7zip 22.01 main
7zip19.00-helper 19.00 main
modern7z 1.8.10 main
nanazip 2.0.450 main 7z | 7zG
7ztm 2.1.1 seumsc_scoop-seu
7zip-beta 22.01 versions
7zip-zstd v21.03-v1.5.0-R2 versions
Additional context/output
Possible Solution
I saw similar questions: JSON parser errors with scoop #10 , but don't know how to solve this problem, could you help me?
System details
Windows version: 11
OS architecture: [e.g. 32bit, 64bit]64bit
PowerShell version: [output of
"$($PSVersionTable.PSVersion)"
]Major Minor Build Revision
5 1 22000 1335
Additional software: [(optional) e.g. ConEmu, Git]
Scoop Configuration
{
"last_update": "2023-01-11T22:11:17.7775487+08:00",
"scoop_branch": "master",
"scoop_repo": "https://github.com/ScoopInstaller/Scoop"
}
//# Your configuration here
The text was updated successfully, but these errors were encountered: