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

Implement debug report generation and adjust issue template #674

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

O-J1
Copy link
Collaborator

@O-J1 O-J1 commented Feb 2, 2025

As discussed on Discord, this PR adds functionality to generate debug logs via running on export_debug.bat.

Users can then upload the resulting debug_report.log when reporting issues on GitHub, great for less experienced users.

A few notes on the implementation and disclaimers:

  • I originally hand wrote .ps1 targeting Windows only
  • Nerogar later sugged he wanted a cross-platform solution instead of windows only, so I converted the script to Python using o3-mini-high, tested it on Windows, and made the necessary modifications to ensure proper functionality. Apologies if its not up to snuff!

It would be great if someone could test this on Linux to confirm cross-platform compatibility.

@Arcitec
Copy link
Contributor

Arcitec commented Feb 7, 2025

I don't have any time at the moment to check any code or comments above, but saw the mention of needing Linux support, so I will have a look this weekend.

@Arcitec
Copy link
Contributor

Arcitec commented Feb 8, 2025

I will have time tomorrow (Sunday) to check this out on Linux. Is there anything in particular you want me to look at or help with?

As for how to launch it on Linux, we can use ./run-cmd.sh generate_debug_report so there's no need to create another script on that platform.

…s, +packet loss, +linux sh and +requirements
@O-J1
Copy link
Collaborator Author

O-J1 commented Feb 9, 2025

I will have time tomorrow (Sunday) to check this out on Linux. Is there anything in particular you want me to look at or help with?

As for how to launch it on Linux, we can use ./run-cmd.sh generate_debug_report so there's no need to create another script on that platform.

Ive added a run_debug.sh hopefully it works. Also @Nerogar here is an example of the log:

debug_report.log

@O-J1 O-J1 requested a review from Nerogar February 9, 2025 01:54
@Arcitec
Copy link
Contributor

Arcitec commented Feb 10, 2025

@O-J1 Alright, here we go.

First of all, fantastic work creating this debug report framework. There are some small things we should fix but overall it's a very good tool and a superb initiative from you. Thank you.

I'll start a code review with the bugs. They are all minor. :)

scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
export_debug.sh Outdated Show resolved Hide resolved
Copy link
Contributor

@Arcitec Arcitec left a comment

Choose a reason for hiding this comment

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

Code review and Linux testing.

Copy link
Contributor

@Arcitec Arcitec left a comment

Choose a reason for hiding this comment

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

Found an issue with processor name fetching on Linux.

scripts/generate_debug_report.py Outdated Show resolved Hide resolved
Copy link
Contributor

@Arcitec Arcitec left a comment

Choose a reason for hiding this comment

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

It suddenly hit me that there's a big bug for non-English users. Fix provided.

requirements-global.txt Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
O-J1 added 2 commits February 11, 2025 20:23
…ug.sh as reccomended, added space in reqs and I attempted to fix raised issues.
@O-J1 O-J1 requested a review from Arcitec February 11, 2025 09:31
@O-J1 O-J1 changed the title Generate debug report and adjust issue template Implement debug report generation and adjust issue template Feb 11, 2025
Copy link
Contributor

@Arcitec Arcitec left a comment

Choose a reason for hiding this comment

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

This is shaping up super nicely! I am so sorry to have found some issues. Back and forth changes are never fun as a contributor, so please don't overwork yourself. I've got a few bugs, found some solutions for Mac users, etc. It's worth looking through these, but after these changes I don't see anything else in its current state. ❤️

.github/ISSUE_TEMPLATE/bug.yml Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Outdated Show resolved Hide resolved
scripts/generate_debug_report.py Show resolved Hide resolved
…nstructions, fixed typos and version for Linux.
@O-J1
Copy link
Collaborator Author

O-J1 commented Feb 14, 2025

Heres a WSL2 output this time from the latest commit.

debug_report.log

I have further changes not yet committed that added type hints, classes and tests but I am not sure if thats overkill, waiting to hear Neros thoughts on the current commit. Im quite happy with it as of commit 1776cbd now 😃

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.

3 participants