Skip to content
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

Filter manager #39 #1613

Merged
merged 117 commits into from
Mar 15, 2024
Merged

Filter manager #39 #1613

merged 117 commits into from
Mar 15, 2024

Conversation

patrickdalla
Copy link
Collaborator

I think it is eligible to PR.

Some filter or filterer type particularity, such as how they are represented in tree, or how they are separated in more than one filter, can be reviewed. For example, in FilterSelectedEdge, only one filter is presented representing all selected edges.

be responsible for the Combo of predefined filters also.
adapts UICaseSearchFilter to extends this class.
CombinedFilterer must implement, preventing it to cache result bitsets,
as it may change.
operand nodes. Solving some concurrency bugs.
@lfcnassif
Copy link
Member

Just pushed the optimization, now it seems to work correctly and the filters are very fast. I'll still implement the TODOs for multivalued string fields.

@lfcnassif
Copy link
Member

I think I'm done, I'll just do some code clean up. Tests by others would be very welcome!

Copy link
Member

@lfcnassif lfcnassif left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this now is good to merge. Thank you @patrickdalla and @wladimirleite for your work on this!

Left as future improvements:

  • Paint Table Tab using red color when a table header filter is applied (done)
  • Put the sorting and numeric scale sliders already used by the MetadataPanel as top components in the new table header filters pop ups

@lfcnassif lfcnassif merged commit 56b85e3 into master Mar 15, 2024
2 checks passed
@lfcnassif lfcnassif deleted the FilterManager_#39 branch March 15, 2024 04:18
@lfcnassif
Copy link
Member

lfcnassif commented Mar 15, 2024

Another future work:

  • Make it possible to re-enable the last filters from the new Filter manager tab, as originally proposed on Filter Manager #39. I think it makes sense to allow enabling filters from a filter manager. I think replicating the filters state to their original tabs, although desired, is not a must.

@lfcnassif
Copy link
Member

  • Paint Table Tab using red color when a table header filter is applied

Done, just pushed to master.

@lfcnassif lfcnassif mentioned this pull request Mar 18, 2024
@lfcnassif
Copy link
Member

@marcus6n now that you finished reviewing #2135, I would like your help to test the features and changes integrated by this PR, because this was a big work and I did many fixes and changes. @patrickdalla is on vacation so he couldn't review and test my changes, but since they were a lot, I would like testing from someone else. What needs to be tested:

  • New Filters panel: all its Filters and its Combined Filter
  • New Table Header Filters: single and multivalued string, date and numeric columns
  • The old Metadata Filter panel, since its code was changed a bit, to test for undesired regressions
  • All existing UI filters and their multiple combination, since their code was changed a bit, testing for unexpected regressions

You can use the master branch for all tests, since this PR was already integrated. Thank you for your help!

@marcus6n
Copy link
Contributor

@lfcnassif Okay, I'll run the tests and get back to you with my feedback once I've completed them! Thanks.

@lfcnassif
Copy link
Member

One tip about testing old filters, after processing a case using master, you can copy it to another folder and replace the contents of iped/lib and iped/localization folders for those from the 4.1.5 version in the copied case. Then open the 2 cases at the same time and compare the filters results between the 2 cases, they must be the same. I've found a behavior regression and fixed it using that approach.

@lfcnassif
Copy link
Member

Just remembered the new context menu fast filter to test. Select a value on the results table, Ctrl+right click it, the fast filter menu will show up. Please test it with single and multivalued columns with string, date and number values.

@marcus6n
Copy link
Contributor

marcus6n commented Mar 25, 2024

Hi @lfcnassif,

I just tested the features and changes integrated by this PR (#1613) and everything worked perfectly! I used two sample files to perform the tests and the filters worked as expected.

@lfcnassif
Copy link
Member

Thank you @marcus6n. By two sample files you mean two sample forensic images, right?

@marcus6n
Copy link
Contributor

@lfcnassif Exactly, I used two samples of forensic images.

@wladimirleite
Copy link
Member

wladimirleite commented Apr 9, 2024

I found a couple of exceptions in the IPED-SearchApp.log that seem to be related to this issue, while working with the new "Filters" tab. They seem pretty harmless, but it should be better to avoid them.

If a node (e.g. "No Bookmarks") is dragged and dropped with the right mouse button (not the "main" left one), the following exception is thrown:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at iped.app.ui.FiltersPanel$7.showPopupMenu(FiltersPanel.java:212)
	at iped.app.ui.FiltersPanel$7.mouseReleased(FiltersPanel.java:229)
	at java.desktop/java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.desktop/java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.desktop/java.awt.Component.processMouseEvent(Unknown Source)
	at java.desktop/javax.swing.JComponent.processMouseEvent(Unknown Source)
	...

If a same node is added twice to the "Combined Filter" tree, when one of them is removed, the following exception is thrown:

Exception in thread "Thread-286" java.lang.NullPointerException
	at iped.app.ui.filterdecisiontree.CombinedFilterer.getBitSet(CombinedFilterer.java:383)
	at iped.app.ui.filterdecisiontree.CombinedFilterer$CombinedBitSet$1.run(CombinedFilterer.java:290)
	at java.base/java.lang.Thread.run(Unknown Source)

@lfcnassif
Copy link
Member

Thank you @wladimirleite for reporting, I'll try to take a look in the afternoon.

@lfcnassif lfcnassif mentioned this pull request Apr 11, 2024
@lfcnassif
Copy link
Member

@patrickdalla, should combined filter allow more than 1 node corresponding to the same filter?

@patrickdalla
Copy link
Collaborator Author

patrickdalla commented Apr 11, 2024 via email

@patrickdalla
Copy link
Collaborator Author

Hi nassif. I am reviewing the code. The clone method was planned (its signature is created), but not really implemented. I am doing it now.

@lfcnassif
Copy link
Member

Hi @patrickdalla, thanks for reviewing and testing. But please do it on #2163, I already pushed some fixes, including clone() related ones. Thanks!

@lfcnassif
Copy link
Member

I also uploaded a video showing another issue there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants