Skip to content

Commit

Permalink
Merge 20241029
Browse files Browse the repository at this point in the history
Dest sha:   bd98591d35775be47531a51faed03ff4c9839328
Source sha: a1e14a5677329b9a90431a0da1fa7d53b66d491d
6e00a363a  bug-1926077: remove enclosing square bracket(s) from module name in signature generation (#6766)  (Bianca Danforth)
9d6804a71  Bug 1914848 - Ignore the functions in libdspatch when generating crash signatures  (Gabriele Svelto)
38e83ef5a  Fix signature generation docs  (Will Kahn-Greene)
  • Loading branch information
willkg committed Oct 30, 2024
1 parent 5be49ce commit 34a872e
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 9 deletions.
6 changes: 3 additions & 3 deletions siggen/cmd_doc.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,11 @@ def main(argv=None):

with open(args.output, "w") as fp:
fp.write(".. THIS IS AUTOGEMERATED USING:\n")
fp.write(" \n")
fp.write("\n")
fp.write(" %s\n" % (" ".join(sys.argv)))
fp.write(" \n")
fp.write("\n")
fp.write("Signature generation ruleset\n")
fp.write("============================n")
fp.write("============================\n")
fp.write("\n")
fp.write("\n")
fp.write(
Expand Down
7 changes: 4 additions & 3 deletions siggen/pipeline.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
.. THIS IS AUTOGEMERATED USING:
./socorro-cmd signature-doc socorro.signature.generator.DEFAULT_RULESET socorro/signature/pipeline.rst
Signature generation ruleset
============================n
============================


This is the signature generation ruleset defined at ``socorro.signature.generator.DEFAULT_RULESET``:

Expand Down
5 changes: 3 additions & 2 deletions siggen/rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,6 @@ def normalize_cpp_function(self, function, line):
if function.endswith(ref):
function = function[: -len(ref)].strip()

# Convert `anonymous namespace' to (anonymous namespace)

# Drop the prefix and return type if there is any if it's not operator
# overloading--operator overloading syntax doesn't have the things
# we're dropping here and can look curious, so don't try
Expand Down Expand Up @@ -247,6 +245,9 @@ def normalize_frame(

# If there's a module, use that
if module:
# Remove extra [ and/or ] at beginning or end if present; see Bug 1926077
module = module.strip("[]")

return module

# If there are unloaded modules, use the first one
Expand Down
15 changes: 15 additions & 0 deletions siggen/siglists/irrelevant_signature_re.txt
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,21 @@ dalvik-jit-code-cache
dalvik-LinearAlloc
data@app@org\.mozilla\.f.*\.apk@classes\.dex
DebugBreak
_dispatch_client_callout
_dispatch_continuation_pop
_dispatch_lane_barrier_sync_invoke_and_complete
_dispatch_main_queue
_dispatch_once_callout
_dispatch_queue_invoke
_dispatch_queue_override_invoke
_dispatch_queue_serial_drain
_dispatch_root_queue
_dispatch_source_invoke
_dispatch_source_latch_and_call
_dispatch_sync_invoke_and_complete_recurse
_dispatch_sync_wait
_dispatch_worker_thread
_dispatch_workloop_worker_thread
do_AddRef
__entry_from_strcat_in_strcpy
enum\$<T>::
Expand Down
2 changes: 1 addition & 1 deletion siggen/socorro_sha.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
bd98591d35775be47531a51faed03ff4c9839328
a1e14a5677329b9a90431a0da1fa7d53b66d491d
5 changes: 5 additions & 0 deletions siggen/tests/test_rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,11 @@ def test_no_mutation(self):
),
"(unloaded unmod)",
),
# no function or line, so uses module; module name has extra bracket(s)
(("module]", "", "\\a\\b\\c\\source", "", "0xfff"), "module"),
(("[module]", "", "\\a\\b\\c\\source", "", "0xfff"), "module"),
(("[module", "", "\\a\\b\\c\\source", "", "0xfff"), "module"),
(("[[[module]]", "", "\\a\\b\\c\\source", "", "0xfff"), "module"),
],
)
def test_normalize_frame(self, args, expected):
Expand Down

0 comments on commit 34a872e

Please sign in to comment.