-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Python: Fix a bunch of QL warnings #8336
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
Conversation
For the most part, these boil down to "some global property holds, and so this relation contains all instances of class `X`". The fix is to explicitly build the cartesian product (which we were already building implicitly anyway) by adding `and exists(var)` to the disjunct that did not mention `var`. Note that these cartesian products are always with singletons on one side, and so should be unproblematic.
These are all implied by the return type of the other side of the equality.
e7e57fe
to
a41f3cc
Compare
c61d340
to
524d17e
Compare
524d17e
to
5a8ba6a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
C#: LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Java 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for doing this!
python/tools/recorded-call-graph-metrics/ql/lib/RecordedCalls.qll
Outdated
Show resolved
Hide resolved
Co-authored-by: yoff <lerchedahl@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
C++ 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Happy to merge this now.
The Field only used in CharPred
-warnings are interesting, but can be tackled later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ruby 👍
Does what it says on the tin. Most of the remaining warnings fall into a few classes:
lib
. Some of these should probably just be deleted (SVN support, anyone?), but may need a formal deprecation first.All of the changes in this PR should be fairly benign, however.
As this doesn't change the API, I don't think a change note is required.