-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Apply minor CodeFactor code quality fixes #5762
Conversation
🤖 Hey, I'm @LmmsBot from github.com/lmms/bot and I made downloads for this pull request, click me to make them magically appear! 🎩
Linux
Windows
🤖{"platform_name_to_artifacts": {"Linux": [{"artifact": {"title": {"title": "(AppImage)", "platform_name": "Linux"}, "link": {"link": "https://11264-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.37%2Bg331644d-linux-x86_64.AppImage"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/11264?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}], "Windows": [{"artifact": {"title": {"title": "32-bit", "platform_name": "Windows"}, "link": {"link": "https://11261-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.37%2Bg331644daa-mingw-win32.exe"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/11261?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}, {"artifact": {"title": {"title": "64-bit", "platform_name": "Windows"}, "link": {"link": "https://11262-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.37%2Bg331644daa-mingw-win64.exe"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/11262?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}, {"artifact": {"title": {"title": "32-bit", "platform_name": "Windows"}, "link": {"link": "https://ci.appveyor.com/api/buildjobs/p2lntmb8q7s03ygc/artifacts/build/lmms-1.3.0-alpha-msvc2017-win32.exe"}}, "build_link": "https://ci.appveyor.com/project/Lukas-W/lmms/builds/36626255"}, {"artifact": {"title": {"title": "64-bit", "platform_name": "Windows"}, "link": {"link": "https://ci.appveyor.com/api/buildjobs/p4b7ge38wb61ai63/artifacts/build/lmms-1.3.0-alpha-msvc2017-win64.exe"}}, "build_link": "https://ci.appveyor.com/project/Lukas-W/lmms/builds/36626255"}, {"artifact": {"title": {"title": "32-bit", "platform_name": "Windows"}, "link": {"link": "https://ci.appveyor.com/api/buildjobs/msgj7dpaga5m87ar/artifacts/build/lmms-1.3.0-alpha-msvc2017-win32.exe"}}, "build_link": "https://ci.appveyor.com/project/Lukas-W/lmms/builds/37322915"}, {"artifact": {"title": {"title": "64-bit", "platform_name": "Windows"}, "link": {"link": "https://ci.appveyor.com/api/buildjobs/m6yspuekwimg4an9/artifacts/build/lmms-1.3.0-alpha-msvc2017-win64.exe"}}, "build_link": "https://ci.appveyor.com/project/Lukas-W/lmms/builds/37322915"}]}, "commit_sha": "2420d5f16323157617e207012f7a062e172b2a80"} |
Could we add https://www.codefactor.io/ to LMMS as a build check? It really is rather good and is free for public projects. |
Tested locally, and everything seems fine. It might be worth someone with a bit more experience checking through things, but from my limited knowledge of XML and CSS, the changes codefactor has recommended seem semantically equivalent. |
Changes in |
LGTM too (been a while I don't use CSS, so I didn't remember the three values option, thought it was either 1, 2 or 4 😄). As for what PhysSong said, if the source checks are sensible to trailing whitespaces the changes on those files could be an issue. Have to check that first, and if it breaks translations the only way to fix those is to manually fix all the source strings in the source code (could use some sed script to make it easier, still would be a bit workful). |
Sorry for the late reply!
You are absolutely right! The translation strings should be verbatim versions of the strings in the source code files. Otherwise, the translation will be missing. To resolve this issue, corresponding C/C++ source files should be edited and then you can regenerate a set of new translation files.
If they've been removed in the source code, they should be removed in the |
I have reverted the changes regarding the translations |
@dan-giddins can you please assist us toggling this tool on for just the items we won't be covering with #4690? For example, this PR makes CSS more consistent and we'd certainly like to have a CI check that handles this and the PR is small enough to be able to turn that on immediately. Sorry for the delay. I have some reservations about using shorthand syntax over readable syntax, but in the end, consistency wins. I've un-archived the codefactor project. Happy to add you as a maintainer if it's needed to get the settings right. For now I've diabled |
@tresf So What should we do with this PR? |
Closing until/unless the OP comes back to help with our implementation. |
@tresf Sorry for the delay. Yes I think I will need to be a maintainer to add it to the project. You could of course do it yourself if you want to limit the number of maintainers on the project. Either way, what we would need to do would be to use GitHub checks. I've installed it for my personal profile: |
Invite sent. Hopefully write access is enough (the codefactor portal suggests it is). |
@tresf is this what you are talking about? |
You can do it, I believe it's read-only and your permissions don't have access to the dangerous stuff. Oddly, I've already done all of this using the service account (there was a bit of ambiguity as to WHO's access I was granting), so I think it's actually asking about this on your own profile. Either way, go ahead and proceed. What I don't like about read-only access to the administrative functions is it may be granting access to some private keys we use for webhooks, something I wouldn't want codefactor to have access to (and I'd expect them to share the same sentiments). |
Minor code quality changes recommended and auto-generated by https://www.codefactor.io/