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

[code_review] AssertionError: Found two functions with the same name #4444

Closed
suhaibmujahid opened this issue Aug 27, 2024 · 0 comments · Fixed by #4445
Closed

[code_review] AssertionError: Found two functions with the same name #4444

suhaibmujahid opened this issue Aug 27, 2024 · 0 comments · Fixed by #4445
Labels
bug Something isn't working code-review

Comments

@suhaibmujahid
Copy link
Member

Found two functions with the same name
  File "/Users/smujahid/repos/mozilla/bugbug/bugbug/code_search/mozilla.py", line 70, in get_function
    assert found_perfect is None, "Found two functions with the same name"
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Users/smujahid/repos/mozilla/bugbug/bugbug/code_search/mozilla.py", line 86, in get_function_by_name
    return self.get_function(
           ^^^^^^^^^^^^^^^^^^
  File "/Users/smujahid/repos/mozilla/bugbug/bugbug/tools/code_review.py", line 804, in request_for_function_declarations
    definitions = function_search.get_function_by_name(
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/smujahid/repos/mozilla/bugbug/bugbug/tools/code_review.py", line 1050, in run (Current frame)
    requested_functions = request_for_function_declarations(
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/smujahid/repos/mozilla/bugbug/venv/lib/python3.11/site-packages/tenacity/__init__.py", line 478, in __call__
    result = fn(*args, **kwargs)
  File "/Users/smujahid/repos/mozilla/bugbug/venv/lib/python3.11/site-packages/tenacity/__init__.py", line 336, in wrapped_f
    return copy(f, *args, **kw)
  File "/Users/smujahid/repos/mozilla/bugbug/scripts/code_review_tool_evaluator.py", line 163, in main
    comments = tool.run(patch)
  File "/Users/smujahid/repos/mozilla/bugbug/scripts/code_review_tool_evaluator.py", line 199, in <module>
    main()
  File "/opt/homebrew/Cellar/[email protected]/3.11.9/Frameworks/Python.framework/Versions/3.11/lib/python3.11/runpy.py", line 88, in _run_code
    exec(code, run_globals)
  File "/opt/homebrew/Cellar/[email protected]/3.11.9/Frameworks/Python.framework/Versions/3.11/lib/python3.11/runpy.py", line 198, in _run_module_as_main
    return _run_code(code, main_globals, None,
AssertionError: Found two functions with the same name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working code-review
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant