Commit Graph

12 Commits

Author SHA1 Message Date
Chris PeBenito
ffd28e90bb Remove permission map parameter from analysis tabs.
This is not the common case.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
6768517a2a TableResultTabWidget: Check all column widths to reduce wide ones.
Previously it was only checking one column.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
fff85bd58d BaseAnalysisTabWidget: Add optional browser pane.
Includes some minor attribute renaming for consistency.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
52f9b509b0 TabRegistry: Check tabs using TabProtocol instead of attribute names.
Only add classes following the tab protocol to the tab registry.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
c02b2628d7 Address issues uncovered by mypy 1.6.1.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
7e9d0fded9 Update to PyQt6.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
cd24446963 setoolsgui: Address new errors in mypy 1.6.0.
Most come from the union-attr check, throwing errors because PyQt returns,
for example, "QObjecet | None", so code is using attributes on the PyQt
object that don't exist on None.

In some cases, classes gained new overridden method implementations that
do type narrowing to ensure a non-None object is returned.

This also includes a new QListView subclass with the above overrides.  With
the new class, there is some light refactoring in ListCriteriaWidget,
moving the selection methods to the new class.

The test code (unit tests and module __main__) simply ignore union-attr
errors, since we want that kind of runtime error to pop loudly.

There are some remaining issues, but they seem to be issues in the PyQt5
typing.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
5f83443516 setoolsgui: Update to Python 3.10 typing syntax and features.
Also clean up lint warnings, such as missing docstrings and shadowing
variables in the __main__ (testing) functions.

No functional change.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
4cb51fcf1e Add DirectedGraphResultTab base class for graph analyses.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-02-14 09:11:35 -05:00
Chris PeBenito
586117b10b Add new apol main window implementation.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-01-31 10:11:55 -05:00
Chris PeBenito
b71f9eda92 QueryResultsUpdater: Handle exceptions and emit a failure signal.
Prevent crashes in the unlikely event there is an exception while a query
is processing.

Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-01-31 10:11:55 -05:00
Chris PeBenito
2edb93e2d5 Add base classes for top level app tabs.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
2024-01-31 10:11:55 -05:00