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

misra mutations test - git diff error fix #1964

Merged
merged 1 commit into from
Jun 4, 2024

Conversation

dzid26
Copy link
Contributor

@dzid26 dzid26 commented May 31, 2024

Mutations test fails due to git diff running in a temp folder. Only when running locally for some reason. Error:

MISRA coverage table doesn't match. Update and commit:
Before: /home/dzid_/openpilot/panda/tests/misra
--------------------------------- Captured stderr call ----------------------------------
HEAD is now at 7cb8f2bc6 Fix #12726: Update for CheckOrderEvaluation (#6448)
fatal: not a git repository: /tmp/tmpowwsj6_q/../.git/modules/panda

This PR patches this problem.


I am still a bit confused though:

  • I verified $DIR, $CPPCHECK_DIR, $PANDA_DIR point to temp folder.
  • However htop shows cppcheck process running in the root, not temp
    image
  • and cppcheck dump files are created in the root (and not deleted):
:~/openpilot/panda/board$ ls -lt
total 391188
-rw-r--r-- 1 dzid_ dzid_ 34325973 May 31 14:41 main.c.14171.dump
-rw-r--r-- 1 dzid_ dzid_        0 May 31 14:41 main.c.14171.ctu-info
-rw-r--r-- 1 dzid_ dzid_    32331 May 31 14:41 main.c.13962.ctu-info
-rw-r--r-- 1 dzid_ dzid_ 34325982 May 31 14:41 main.c.13962.dump
-rw-r--r-- 1 dzid_ dzid_        0 May 31 14:40 main.c.13794.ctu-info

But regardless, I think this fix is necessary.

Edit: figured out the problem with running in root was due to pytest automatic test collection and execution of test_*.sh #1970 (comment)

@dzid26 dzid26 marked this pull request as draft May 31, 2024 10:58
@dzid26 dzid26 changed the title misra mutations test - fix tables overwrite by multiple workers misra mutations test - git diff error fix May 31, 2024
@dzid26 dzid26 marked this pull request as ready for review May 31, 2024 17:57
@adeebshihadeh adeebshihadeh merged commit b6b8144 into commaai:master Jun 4, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants