ejaaskel / Yocto-CVE-Parser

11 stars 1 forks source link

KeyError: 'scorev2' #4

Open RobertBerger opened 5 days ago

RobertBerger commented 5 days ago
./cve-parser.py -f issues/cve-summary-20241108164125.json -u -e

Traceback (most recent call last):
  File "/home/student/projects/resy-playground/sources/Yocto-CVE-Parser/./cve-parser.py", line 180, in <module>
    main()
  File "/home/student/projects/resy-playground/sources/Yocto-CVE-Parser/./cve-parser.py", line 172, in main
    issue_list = create_issue_list(args, data)
  File "/home/student/projects/resy-playground/sources/Yocto-CVE-Parser/./cve-parser.py", line 95, in create_issue_list
    j['scorev2'] = float(j['scorev2'])
KeyError: 'scorev2'
``
[cve-summary-20241108164125.json.tar.gz](https://github.com/user-attachments/files/17682325/cve-summary-20241108164125.json.tar.gz)
RobertBerger commented 5 days ago

I updated everything to master and this also fails with KeyError: 'scorev2'

Image CVE JSON report stored in: /workdir/build/multi-v7-ml-debug-training-master/tmp/work/multi_v7_ml-resy-linux-gnueabi/core-image-sato-sdk/1.0/deploy-core-image-sato-sdk-image-complete/core-image-sato-sdk-multi-v7-ml.rootfs-20241108190212.json

Maybe I am not using the right file, or something changed in the format.

ejaaskel commented 4 days ago

Thanks for reporting, I'll investigate if the format of the file has changed, or maybe the CVS v2 scores are being removed in the newer versions. Whatever the case, I guess it'd make sense to add some NaN type of value instead of failing the whole process