summaryrefslogtreecommitdiffstats
path: root/src/utils/sw_inventory.py
Commit message (Collapse)AuthorAgeFilesLines
* src: use explicit exception types in except Exception blocksAlejandro Sirgo Rica2024-04-031-1/+1
| | | | | | | | Capture only the relevant exception types in each except block. The capture of the Exception type means hiding information for unhandled error cases, even for syntax errors in the codebase. Using a more fine grained exception filtering improves error traceability.
* utils: handle exceptions caused by the hivex packageAlejandro Sirgo Rica2024-03-081-3/+6
| | | | | | The mage creation process was being interrupted by an error trying to read the Windows registry by the Hivex library. Now the exceptions are handled and an error is reported.
* utils: sw_inventory: report unknown OS for software inventoryv1.3.2-2OpenGnSys Support Team2023-11-171-1/+2
| | | | | | Users can create an image of a filesystem that contains no OS, therefore, instead of rising an exception when no OS is detected, deliver a "unknown" OS and an empty list of software.
* sw_inventory: ignore invalid windows programsJose M. Guisado2023-05-091-5/+10
| | | | | | | | | | | | | | | | | | | | | | | Don't raise exception if any windows program is missing DisplayName node in the windows registry. This attribute/node should contain the program's name. This name is used as the package's name in the software set (software inventory). This patch should be considered a hotfix, python-hivex does not report any helpful message about this error. (2023-05-09 14:43:13) ogClient: [ERROR] - Unexpected error Traceback (most recent call last): [...] RuntimeError: Success Before this patch, image creation *might* fail because it cannot create the software inventory associated with the image due to the previously described error. The software inventory is part of the response payload of the image creation command (see src/ogRest:image_create). Fixes: 04bb35bd86b5 (live: rewrite software inventory)
* src: add missing copyright noticesv1.2.8Jose M. Guisado2023-04-181-0/+8
|
* utils: rename inventory.py to sw_inventory.pyJose M. Guisado2023-04-181-0/+118
Rename software inventory file to sw_inventory to better distinguish it from a future hardware inventory code. In the future sw_inventory and hw_inventory might be merged together once each file is tidied up.