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

Improve WineCommand.run() #2748

Merged
merged 11 commits into from
May 4, 2023
Merged

Conversation

StoneMoe
Copy link
Contributor

@StoneMoe StoneMoe commented Feb 27, 2023

Description

This PR:

  • make WineCommand.run() return Result
  • make WineCommand.run() more robust
  • Add property ok, ready, has_data for Result, to make Result checking more readable
  • Fix match case for multiple value condition
  • Revert encoding detection to chardet implementation
  • Bump requests to 2.28.1

Fixes #2731
Fixes #2799
Fixes #2757

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes.
Provide instructions so we can reproduce.

  • WIP

@StoneMoe StoneMoe marked this pull request as draft February 27, 2023 05:35
@github-actions
Copy link
Contributor

github-actions bot commented Feb 27, 2023

Pylint result on modfied files:
************* Module bottles.frontend.views.bottle_versioning
bottles/frontend/views/bottle_versioning.py:30:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:32:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:82:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:83:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:134:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:149:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:149:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_versioning.py:21:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/views/bottle_versioning.py:66:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_versioning.py:102:29: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/views/bottle_versioning.py:72:21: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_versioning.py:146:27: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/views/bottle_versioning.py:137:24: W0613: Unused argument 'widget' (unused-argument)
************* Module bottles.frontend.views.importer
bottles/frontend/views/importer.py:29:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/importer.py:31:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/importer.py:20:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/views/importer.py:65:27: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/views/importer.py:90:31: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/views/importer.py:123:8: W0622: Redefining built-in 'filter' (redefined-builtin)
bottles/frontend/views/importer.py:30:0: R0903: Too few public methods (1/2) (too-few-public-methods)
************* Module bottles.frontend.views.bottle_details
bottles/frontend/views/bottle_details.py:50:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:52:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:115:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:117:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:118:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:344:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:346:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:501:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/views/bottle_details.py:24:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/views/bottle_details.py:154:12: W0105: String statement has no effect (pointless-string-statement)
bottles/frontend/views/bottle_details.py:171:56: C0103: Argument name "x" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:171:59: C0103: Argument name "y" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:171:4: R0913: Too many arguments (6/5) (too-many-arguments)
bottles/frontend/views/bottle_details.py:184:25: C0103: Argument name "a" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:184:28: C0103: Argument name "b" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:184:25: W0613: Unused argument 'a' (unused-argument)
bottles/frontend/views/bottle_details.py:184:28: W0613: Unused argument 'b' (unused-argument)
bottles/frontend/views/bottle_details.py:171:22: W0613: Unused argument 'drop_target' (unused-argument)
bottles/frontend/views/bottle_details.py:171:56: W0613: Unused argument 'x' (unused-argument)
bottles/frontend/views/bottle_details.py:171:59: W0613: Unused argument 'y' (unused-argument)
bottles/frontend/views/bottle_details.py:171:62: W0613: Unused argument 'user_data' (unused-argument)
bottles/frontend/views/bottle_details.py:193:36: C0103: Argument name "x" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:193:39: C0103: Argument name "y" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:193:23: W0613: Unused argument 'drop_target' (unused-argument)
bottles/frontend/views/bottle_details.py:193:36: W0613: Unused argument 'x' (unused-argument)
bottles/frontend/views/bottle_details.py:193:39: W0613: Unused argument 'y' (unused-argument)
bottles/frontend/views/bottle_details.py:197:23: W0613: Unused argument 'drop_target' (unused-argument)
bottles/frontend/views/bottle_details.py:237:18: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:339:31: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:350:30: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:357:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:361:41: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:392:29: C0103: Argument name "a" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:392:32: C0103: Argument name "b" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/views/bottle_details.py:392:29: W0613: Unused argument 'a' (unused-argument)
bottles/frontend/views/bottle_details.py:392:32: W0613: Unused argument 'b' (unused-argument)
bottles/frontend/views/bottle_details.py:369:29: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:369:37: W0613: Unused argument 'args' (unused-argument)
bottles/frontend/views/bottle_details.py:438:27: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/views/bottle_details.py:422:23: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:470:26: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:486:31: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:516:37: W0613: Unused argument 'response_id' (unused-argument)
bottles/frontend/views/bottle_details.py:534:4: W0105: String statement has no effect (pointless-string-statement)
bottles/frontend/views/bottle_details.py:539:26: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:543:24: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:547:25: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:550:27: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:554:22: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:559:18: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:563:30: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:567:31: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:571:30: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:575:26: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/views/bottle_details.py:581:18: W0613: Unused argument 'result' (unused-argument)
bottles/frontend/views/bottle_details.py:581:31: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/views/bottle_details.py:607:17: R1719: The if expression can be replaced with 'not test' (simplifiable-if-expression)
bottles/frontend/views/bottle_details.py:609:12: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.frontend.windows.installer
bottles/frontend/windows/installer.py:26:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/installer.py:28:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/installer.py:72:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/installer.py:74:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/installer.py:20:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/windows/installer.py:27:0: R0903: Too few public methods (0/2) (too-few-public-methods)
bottles/frontend/windows/installer.py:141:8: W0702: No exception type(s) specified (bare-except)
bottles/frontend/windows/installer.py:163:8: R1710: Either all return statements in a function should return an expression, or none of them should. (inconsistent-return-statements)
bottles/frontend/windows/installer.py:163:31: W0613: Unused argument 'error' (unused-argument)
************* Module bottles.frontend.windows.onboard
bottles/frontend/windows/onboard.py:27:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/onboard.py:29:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/onboard.py:69:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/windows/onboard.py:20:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/windows/onboard.py:83:40: W0613: Unused argument 'key' (unused-argument)
bottles/frontend/windows/onboard.py:89:4: W1113: Keyword argument before variable positional arguments list in the definition of __page_changed function (keyword-arg-before-vararg)
bottles/frontend/windows/onboard.py:89:29: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/windows/onboard.py:113:8: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/windows/onboard.py:112:15: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/windows/onboard.py:117:42: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/windows/onboard.py:115:31: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/windows/onboard.py:145:30: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/windows/onboard.py:150:26: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/windows/onboard.py:161:29: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/windows/onboard.py:123:16: W0238: Unused private member `OnboardDialog.__installing` (unused-private-member)
bottles/frontend/windows/onboard.py:127:8: W0238: Unused private member `OnboardDialog.__installing` (unused-private-member)
bottles/frontend/windows/onboard.py:28:0: R0903: Too few public methods (1/2) (too-few-public-methods)
************* Module bottles.frontend.cli.cli
bottles/frontend/cli/cli.py:31:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:31:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:76:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:76:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:79:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:79:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:79:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:82:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:82:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:82:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:98:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:99:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:103:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:103:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:103:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:103:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:109:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:109:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:109:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:109:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:138:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:138:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:655:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/cli/cli.py:34:0: C0103: Constant name "pkgdatadir" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/frontend/cli/cli.py:41:0: C0413: Import "from gi.repository import Gio" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:43:0: C0413: Import "from bottles.frontend.params import APP_ID" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:44:0: C0413: Import "from bottles.backend.globals import Paths" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:45:0: C0413: Import "from bottles.backend.health import HealthChecker" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:46:0: C0413: Import "from bottles.backend.managers.manager import Manager" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:47:0: C0413: Import "from bottles.backend.models.config import BottleConfig" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:48:0: C0413: Import "from bottles.backend.wine.cmd import CMD" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:49:0: C0413: Import "from bottles.backend.wine.control import Control" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:50:0: C0413: Import "from bottles.backend.wine.executor import WineExecutor" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:51:0: C0413: Import "from bottles.backend.wine.winecommand import WineCommand" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:52:0: C0413: Import "from bottles.backend.wine.reg import Reg" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:53:0: C0413: Import "from bottles.backend.wine.winepath import WinePath" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:54:0: C0413: Import "from bottles.backend.wine.regedit import Regedit" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:55:0: C0413: Import "from bottles.backend.wine.taskmgr import Taskmgr" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:56:0: C0413: Import "from bottles.backend.wine.uninstaller import Uninstaller" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:57:0: C0413: Import "from bottles.backend.wine.winecfg import WineCfg" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:58:0: C0413: Import "from bottles.backend.wine.explorer import Explorer" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:59:0: C0413: Import "from bottles.backend.wine.regkeys import RegKeys" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:60:0: C0413: Import "from bottles.backend.runner import Runner" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:61:0: C0413: Import "from bottles.backend.utils import json" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:62:0: C0413: Import "from bottles.backend.utils.manager import ManagerUtils" should be placed at the top of the module (wrong-import-position)
bottles/frontend/cli/cli.py:215:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:217:12: C0103: Variable name "hc" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:220:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:237:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:241:16: C0103: Variable name "b" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:267:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:269:8: C0206: Consider iterating with .items() (consider-using-dict-items)
bottles/frontend/cli/cli.py:269:12: C0103: Variable name "c" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:284:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:292:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:296:16: C0103: Variable name "p" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:310:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:348:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:356:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:364:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:396:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:405:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:430:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:437:19: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:440:20: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:443:20: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:445:20: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:448:24: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:455:15: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:469:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:479:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:489:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:499:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:548:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:562:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:566:16: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:612:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:631:12: R1722: Consider using 'sys.exit' instead (consider-using-sys-exit)
bottles/frontend/cli/cli.py:644:13: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/frontend/cli/cli.py:644:43: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:646:19: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/cli/cli.py:153:4: W0238: Unused private member `CLI.__clear()` (unused-private-member)
************* Module bottles.frontend.widgets.program
bottles/frontend/widgets/program.py:22:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/widgets/program.py:62:4: R0913: Too many arguments (6/5) (too-many-arguments)
bottles/frontend/widgets/program.py:76:16: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/widgets/program.py:107:12: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/frontend/widgets/program.py:110:8: W0105: String statement has no effect (pointless-string-statement)
bottles/frontend/widgets/program.py:268:16: W0212: Access to a protected member __library of a client class (protected-access)
bottles/frontend/widgets/program.py:268:16: W0238: Unused private member `ProgramEntry.__library` (unused-private-member)
************* Module bottles.frontend.widgets.component
bottles/frontend/widgets/component.py:92:45: W0511: TODO: unimplemented (fixme)
bottles/frontend/widgets/component.py:32:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/component.py:34:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/component.py:36:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/component.py:37:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/component.py:74:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/component.py:138:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/component.py:21:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/widgets/component.py:85:35: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/widgets/component.py:83:23: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/component.py:105:27: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/widgets/component.py:103:24: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/component.py:121:25: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/component.py:129:4: R1710: Either all return statements in a function should return an expression, or none of them should. (inconsistent-return-statements)
bottles/frontend/widgets/component.py:166:0: R0903: Too few public methods (0/2) (too-few-public-methods)
************* Module bottles.frontend.widgets.library
bottles/frontend/widgets/library.py:112:34: W0511: TODO: Remove from list (fixme)
bottles/frontend/widgets/library.py:118:26: W0511: TODO: remove entry from library (fixme)
bottles/frontend/widgets/library.py:34:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:36:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:58:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:71:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:72:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:74:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:77:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:77:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:79:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:80:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:89:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:108:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:108:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:109:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:109:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/library.py:67:12: W0719: Raising too general exception: Exception (broad-exception-raised)
bottles/frontend/widgets/library.py:106:4: R1710: Either all return statements in a function should return an expression, or none of them should. (inconsistent-return-statements)
bottles/frontend/widgets/library.py:122:60: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/widgets/library.py:140:24: W0613: Unused argument 'result' (unused-argument)
bottles/frontend/widgets/library.py:140:38: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/widgets/library.py:157:0: W0613: Unused argument 'args' (unused-argument)
bottles/frontend/widgets/library.py:160:29: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/library.py:160:37: W0613: Unused argument 'with_terminal' (unused-argument)
bottles/frontend/widgets/library.py:170:24: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/library.py:173:27: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/library.py:179:0: W0613: Unused argument 'args' (unused-argument)
bottles/frontend/widgets/library.py:183:0: W0613: Unused argument 'args' (unused-argument)
bottles/frontend/widgets/library.py:189:4: W0221: Number of parameters was 2 in 'Box.hide' and is now 1 in overriding 'LibraryEntry.hide' method (arguments-differ)
bottles/frontend/widgets/library.py:189:4: W0221: Variadics removed in overriding 'LibraryEntry.hide' method (arguments-differ)
bottles/frontend/widgets/library.py:192:4: W0221: Number of parameters was 2 in 'Box.show' and is now 1 in overriding 'LibraryEntry.show' method (arguments-differ)
bottles/frontend/widgets/library.py:192:4: W0221: Variadics removed in overriding 'LibraryEntry.show' method (arguments-differ)
bottles/frontend/widgets/library.py:136:4: W0238: Unused private member `LibraryEntry.__is_alive(self)` (unused-private-member)
************* Module bottles.frontend.widgets.importer
bottles/frontend/widgets/importer.py:25:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/importer.py:27:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/frontend/widgets/importer.py:18:0: E0611: No name 'Adw' in module 'gi.repository' (no-name-in-module)
bottles/frontend/widgets/importer.py:58:32: W0613: Unused argument 'widget' (unused-argument)
bottles/frontend/widgets/importer.py:63:33: W0613: Unused argument 'error' (unused-argument)
bottles/frontend/widgets/importer.py:61:32: W0613: Unused argument 'widget' (unused-argument)
************* Module bottles.backend.globals
bottles/backend/globals.py:85:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/globals.py:85:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/globals.py:86:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/globals.py:86:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/globals.py:26:0: R0903: Too few public methods (1/2) (too-few-public-methods)
bottles/backend/globals.py:64:0: R0903: Too few public methods (0/2) (too-few-public-methods)
bottles/backend/globals.py:78:0: C0103: Constant name "vkbasalt_available" doesn't conform to UPPER_CASE naming style (invalid-name)
************* Module bottles.backend.state
bottles/backend/state.py:15:4: C0103: Class constant name "ComponentsInstall" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:19:4: C0103: Class constant name "ComponentsFetching" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:20:4: C0103: Class constant name "DependenciesFetching" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:21:4: C0103: Class constant name "InstallersFetching" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:22:4: C0103: Class constant name "ComponentsOrganizing" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:23:4: C0103: Class constant name "DependenciesOrganizing" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:24:4: C0103: Class constant name "InstallersOrganizing" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:29:4: C0103: Class constant name "ManagerLocalBottlesLoaded" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:31:4: C0103: Class constant name "RepositoryFetched" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:32:4: C0103: Class constant name "NetworkStatusChanged" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:34:4: C0103: Class constant name "GNotification" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:35:4: C0103: Class constant name "GShowUri" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:38:4: C0103: Class constant name "TaskAdded" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:39:4: C0103: Class constant name "TaskRemoved" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:40:4: C0103: Class constant name "TaskUpdated" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/backend/state.py:49:0: R0903: Too few public methods (1/2) (too-few-public-methods)
bottles/backend/state.py:53:0: R0903: Too few public methods (1/2) (too-few-public-methods)
bottles/backend/state.py:125:16: C0103: Variable name "rv" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/state.py:210:12: C0103: Variable name "fn" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.wine.winecommand
bottles/backend/wine/winecommand.py:262:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/winecommand.py:481:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/winecommand.py:481:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/winecommand.py:581:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/winecommand.py:581:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/winecommand.py:84:4: R0913: Too many arguments (11/5) (too-many-arguments)
bottles/backend/wine/winecommand.py:128:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:134:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:166:8: C0103: Variable name "ld" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:184:16: C0103: Variable name "e" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:193:19: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:212:20: C0103: Variable name "ld" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:358:24: C0103: Variable name "p" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:365:20: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:369:51: E1136: Value 'gpu['prime']['integrated']' is unsubscriptable (unsubscriptable-object)
bottles/backend/wine/winecommand.py:371:20: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:165:8: W0612: Unused variable 'is_nvidia' (unused-variable)
bottles/backend/wine/winecommand.py:416:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:426:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:434:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:481:32: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/winecommand.py:490:21: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/backend/wine/winecommand.py:490:49: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:497:21: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/backend/wine/winecommand.py:497:49: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:501:16: C0103: Variable name "st" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:513:20: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/winecommand.py:581:12: C0103: Variable name "s" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:583:12: C0103: Variable name "s" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:591:8: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/winecommand.py:602:8: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/winecommand.py:639:12: R1705: Unnecessary "else" after "return", remove the "else" and de-indent the code inside it (no-else-return)
bottles/backend/wine/winecommand.py:677:8: C0103: Variable name "rv" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:679:12: C0103: Variable name "rv" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:685:12: C0103: Variable name "rv" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:656:23: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/winecommand.py:705:17: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/backend/wine/winecommand.py:705:41: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:709:17: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/backend/wine/winecommand.py:709:41: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winecommand.py:711:17: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/backend/wine/winecommand.py:711:41: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.wine.winebridge
bottles/backend/wine/winebridge.py:42:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winebridge.py:46:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winebridge.py:2:0: W0611: Unused NewType imported from typing (unused-import)
************* Module bottles.backend.wine.executor
bottles/backend/wine/executor.py:250:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/executor.py:23:4: R0913: Too many arguments (16/5) (too-many-arguments)
bottles/backend/wine/executor.py:140:4: R1710: Either all return statements in a function should return an expression, or none of them should. (inconsistent-return-statements)
bottles/backend/wine/executor.py:198:8: E1111: Assigning result of a function call, where the function has no return (assignment-from-no-return)
bottles/backend/wine/executor.py:296:8: E1111: Assigning result of a function call, where the function has no return (assignment-from-no-return)
bottles/backend/wine/executor.py:310:8: E1111: Assigning result of a function call, where the function has no return (assignment-from-no-return)
bottles/backend/wine/executor.py:324:8: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/executor.py:324:11: C0103: Variable name "h" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/executor.py:353:21: W1202: Use lazy % or % formatting in logging functions (logging-format-interpolation)
bottles/backend/wine/executor.py:356:12: C0103: Variable name "m" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.wine.uninstaller
bottles/backend/wine/uninstaller.py:32:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/wine/uninstaller.py:1:0: W0611: Unused NewType imported from typing (unused-import)
************* Module bottles.backend.wine.winepath
bottles/backend/wine/winepath.py:2:0: W0611: Unused NewType imported from typing (unused-import)
************* Module bottles.backend.wine.reg
bottles/backend/wine/reg.py:54:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/reg.py:56:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/reg.py:54:45: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/reg.py:104:13: W1514: Using open without explicitly specifying an encoding (unspecified-encoding)
bottles/backend/wine/reg.py:104:36: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.wine.wineserver
bottles/backend/wine/wineserver.py:25:14: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/wineserver.py:40:14: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/wineserver.py:63:8: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
************* Module bottles.backend.wine.icinfo
bottles/backend/wine/icinfo.py:39:0: C0305: Trailing newlines (trailing-newlines)
bottles/backend/wine/icinfo.py:10:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/icinfo.py:11:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/icinfo.py:14:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/icinfo.py:17:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/wine/icinfo.py:21:34: E1101: Instance of 'Result' has no 'split' member (no-member)
bottles/backend/wine/icinfo.py:25:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/icinfo.py:28:15: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/icinfo.py:1:0: W0611: Unused NewType imported from typing (unused-import)
************* Module bottles.backend.wine.net
bottles/backend/wine/net.py:46:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/net.py:47:12: C0103: Variable name "r" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/net.py:1:0: W0611: Unused NewType imported from typing (unused-import)
************* Module bottles.backend.wine.winedbg
bottles/backend/wine/winedbg.py:41:12: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:42:12: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:45:16: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:46:16: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:48:12: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:61:16: C0103: Variable name "w" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:107:16: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/wine/winedbg.py:118:16: C0103: Variable name "p" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/wine/winedbg.py:4:0: W0611: Unused NewType imported from typing (unused-import)
************* Module bottles.backend.models.result
bottles/backend/models/result.py:19:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/models/result.py:43:25: C0103: Argument name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/models/result.py:47:4: C0103: Attribute name "ok" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.utils.generic
bottles/backend/utils/generic.py:92:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/utils/generic.py:105:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/utils/generic.py:105:0: W1405: Quote delimiter " is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/utils/generic.py:87:4: W0702: No exception type(s) specified (bare-except)
bottles/backend/utils/generic.py:80:8: C0415: Import outside toplevel (ctypes) (import-outside-toplevel)
************* Module bottles.backend.managers.installer
bottles/backend/managers/installer.py:408:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/managers/installer.py:410:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/managers/installer.py:410:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/managers/installer.py:451:0: W1405: Quote delimiter ' is inconsistent with the rest of the file (inconsistent-quotes)
bottles/backend/managers/installer.py:102:16: C0103: Variable name "c" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/installer.py:102:20: I1101: Module 'pycurl' has no 'Curl' member, but source is unavailable. Consider adding this module to extension-pkg-allow-list if you want to perform analysis based on run-time introspection of living objects. (c-extension-no-member)
bottles/backend/managers/installer.py:104:38: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/managers/installer.py:149:16: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/installer.py:152:20: C0103: Variable name "f" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/installer.py:163:12: C0103: Variable name "st" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/installer.py:250:8: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/managers/installer.py:229:4: R1710: Either all return statements in a function should return an expression, or none of them should. (inconsistent-return-statements)
bottles/backend/managers/installer.py:274:12: C0103: Variable name "d" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/installer.py:302:15: C0103: Variable name "v" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/installer.py:346:4: R0913: Too many arguments (6/5) (too-many-arguments)
bottles/backend/managers/installer.py:433:16: C0103: Variable name "d" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.managers.component
bottles/backend/managers/component.py:83:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:120:4: R0913: Too many arguments (6/5) (too-many-arguments)
bottles/backend/managers/component.py:139:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:150:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:157:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:162:12: C0103: Variable name "c" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/component.py:162:16: I1101: Module 'pycurl' has no 'Curl' member, but source is unavailable. Consider adding this module to extension-pkg-allow-list if you want to perform analysis based on run-time introspection of living objects. (c-extension-no-member)
bottles/backend/managers/component.py:172:19: I1101: Module 'pycurl' has no 'error' member, but source is unavailable. Consider adding this module to extension-pkg-allow-list if you want to perform analysis based on run-time introspection of living objects. (c-extension-no-member)
bottles/backend/managers/component.py:180:16: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:196:20: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:208:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:214:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:257:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:278:16: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:263:18: R1732: Consider using 'with' for resource-allocating operations (consider-using-with)
bottles/backend/managers/component.py:235:16: W0613: Unused argument 'name' (unused-argument)
bottles/backend/managers/component.py:321:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:332:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:340:8: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:351:8: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/component.py:451:15: W0718: Catching too general exception Exception (broad-exception-caught)
bottles/backend/managers/component.py:451:8: C0103: Variable name "e" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/component.py:455:8: W0105: String statement has no effect (pointless-string-statement)
************* Module bottles.backend.managers.dependency
bottles/backend/managers/dependency.py:84:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/dependency.py:102:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/dependency.py:113:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/dependency.py:127:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/dependency.py:142:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/dependency.py:159:12: W0105: String statement has no effect (pointless-string-statement)
bottles/backend/managers/dependency.py:431:12: C0103: Variable name "d" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/dependency.py:497:15: W0718: Catching too general exception Exception (broad-exception-caught)
bottles/backend/managers/dependency.py:497:8: C0103: Variable name "e" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/dependency.py:574:15: W0718: Catching too general exception Exception (broad-exception-caught)
bottles/backend/managers/dependency.py:548:20: C0103: Variable name "fg" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/dependency.py:574:8: C0103: Variable name "e" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/dependency.py:673:8: C0103: Variable name "rk" doesn't conform to snake_case naming style (invalid-name)
bottles/backend/managers/dependency.py:680:8: C0103: Variable name "rk" doesn't conform to snake_case naming style (invalid-name)
************* Module bottles.backend.managers.sandbox
bottles/backend/managers/sandbox.py:27:4: R0913: Too many arguments (12/5) (too-many-arguments)
************* Module bottles.tests.backend.state.test_events
bottles/tests/backend/state/test_events.py:10:4: C0103: Class constant name "SimpleEvent" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/tests/backend/state/test_events.py:11:4: C0103: Class constant name "WaitAfterDone" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/tests/backend/state/test_events.py:12:4: C0103: Class constant name "SetResetEvent" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/tests/backend/state/test_events.py:13:4: C0103: Class constant name "WaitSingleton" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/tests/backend/state/test_events.py:14:4: C0103: Class constant name "DoneSingleton" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/tests/backend/state/test_events.py:15:4: C0103: Class constant name "CorrectFlagDone" doesn't conform to UPPER_CASE naming style (invalid-name)
bottles/tests/backend/state/test_events.py:32:4: C0103: Variable name "t1" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:62:4: C0103: Variable name "t1" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:71:4: C0103: Variable name "t2" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:80:4: C0103: Variable name "t1" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:91:4: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:99:4: C0103: Variable name "t1" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:102:4: C0103: Variable name "t2" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:105:4: C0103: Variable name "t3" doesn't conform to snake_case naming style (invalid-name)
bottles/tests/backend/state/test_events.py:108:15: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:116:4: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:120:15: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:123:15: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:126:15: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:131:11: W0212: Access to a protected member _EVENTS of a client class (protected-access)
bottles/tests/backend/state/test_events.py:135:15: W0212: Access to a protected member _EVENTS of a client class (protected-access)
************* Module bottles.tests.backend.manager.test_manager
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.backend.managers.epicgamesstore:[77:89]
==bottles.backend.managers.ubisoftconnect:[119:131]
                    "path": _path,
                    "folder": _folder,
                    "icon": "com.usebottles.bottles-program",
                    "dxvk": config.Parameters.dxvk,
                    "vkd3d": config.Parameters.vkd3d,
                    "dxvk_nvapi": config.Parameters.dxvk_nvapi,
                    "fsr": config.Parameters.fsr,
                    "virtual_desktop": config.Parameters.virtual_desktop,
                    "pulseaudio_latency": config.Parameters.pulseaudio_latency,
                    "id": str(uuid.uuid4()),
                })
        return games (duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.bottle_dependencies:[80:101]
==bottles.frontend.views.bottle_installers:[74:93]
        text = row.get_title().lower() + row.get_subtitle().lower()
        if terms.lower() in text:
            return True
        return False
def empty_list(self):
    for r in self.__registry:
        if r.get_parent() is not None:
            r.get_parent().remove(r)
    self.__registry = []

def update(self, widget=False, config=None):
    """
    This function update the installers list with the
    supported by the manager.
    """
    if config is None:
        config = BottleConfig()
    self.config = config (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.gamescope:[98:110]
==bottles.frontend.windows.vmtouch:[53:65]
for setting in settings.keys():
self.manager.update_config(
config=self.config,
key=setting,
value=settings[setting],
scope="Parameters"
)

    self.destroy()

def __save(self, *_args):
    GLib.idle_add(self.__idle_save) (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.bottle_details:[396:406]
==bottles.frontend.views.list:[126:136]
dialog = Gtk.FileChooserNative.new(
title=("Select Executable"),
action=Gtk.FileChooserAction.OPEN,
parent=self.window,
accept_label=
("Run")
)

        add_executable_filters(dialog)
        add_all_filters(dialog)
        dialog.set_modal(True) (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.gamescope:[35:51]
==bottles.frontend.windows.vmtouch:[28:45]
btn_save = Gtk.Template.Child()
btn_cancel = Gtk.Template.Child()

# endregion

def __init__(self, window, config, **kwargs):
    super().__init__(**kwargs)
    self.set_transient_for(window)

    # common variables and references
    self.window = window
    self.manager = window.manager
    self.config = config

    # connect signals
    self.btn_save.connect("clicked", self.__save)

(duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.widgets.library:[136:146]
==bottles.frontend.widgets.program:[155:165]
winedbg = WineDbg(self.config)

    @GtkUtils.run_in_main_loop
    def set_watcher(_result=False, _error=False):
        nonlocal winedbg
        self.__reset_buttons()

        RunAsync(
            winedbg.wait_for_process,
            callback=self.__reset_buttons, (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.duplicate:[34:47]
==bottles.frontend.windows.upgradeversioning:[31:45]
stack_switcher = Gtk.Template.Child()
progressbar = Gtk.Template.Child()

# endregion

def __init__(self, parent, **kwargs):
    super().__init__(**kwargs)
    self.set_transient_for(parent.window)

    # common variables and references
    self.parent = parent
    self.config = parent.config

(duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.importer:[157:166]
==bottles.frontend.views.new:[138:149]
)

    add_yaml_filters(dialog)
    add_all_filters(dialog)
    dialog.set_modal(True)
    dialog.connect("response", set_path)
    dialog.show()

def go_back(self, *_args): (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.bottle_preferences:[301:310]
==bottles.frontend.views.new:[157:168]
action=Gtk.FileChooserAction.SELECT_FOLDER,
parent=self.window
)

    dialog.set_modal(True)
    dialog.connect("response", set_path)
    dialog.show()

def create_bottle(self, *_args) -> None:
    """ Starts creating the bottle. """
    # set widgets states (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.bottle_details:[502:516]
==bottles.frontend.views.bottle_preferences:[744:750]
)
dialog.add_response("cancel", _("_Cancel"))
dialog.add_response("ok", _("_Delete"))
dialog.set_response_appearance("ok", Adw.ResponseAppearance.DESTRUCTIVE)
dialog.connect("response", handle_response)
dialog.present() (duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.backend.repos.dependency:[25:30]
==bottles.backend.repos.installer:[25:32]
if name in self.catalog:
entry = self.catalog[name]
url = f"{self.url}/{entry['Category']}/{name}.yml"
return self.get_manifest(url, plain)
return False (duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.exclusionpatterns:[72:80]
==bottles.frontend.windows.sandbox:[32:39]
super().init(**kwargs)
self.set_transient_for(window)

    # common variables and references
    self.window = window
    self.manager = window.manager
    self.config = config (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.envvars:[28:38]
==bottles.frontend.windows.exclusionpatterns:[28:38]
btn_remove = Gtk.Template.Child()
# endregion

def __init__(self, parent, env, **kwargs):
    super().__init__(**kwargs)

    # common variables and references
    self.parent = parent
    self.manager = parent.window.manager
    self.config = parent.config (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.dlloverrides:[90:98]
==bottles.frontend.windows.envvars:[84:92]
super().init(**kwargs)
self.set_transient_for(window)

    # common variables and references
    self.window = window
    self.manager = window.manager
    self.config = config

(duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.backend.wine.executor:[93:99]
==bottles.frontend.windows.launchoptions:[121:127]
dxvk = config.Parameters.dxvk
vkd3d = config.Parameters.vkd3d
nvapi = config.Parameters.dxvk_nvapi
fsr = config.Parameters.fsr
virt_desktop = config.Parameters.virtual_desktop
(duplicate-code)
bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.widgets.program:[227:234]
==bottles.frontend.windows.launchoptions:[189:195]
config=self.config,
key=self.program["id"],
value=self.program,
scope="External_Programs"
).data["config"]

def remove_program(self, _widget=None): (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.drives:[106:114]
==bottles.frontend.windows.gamescope:[41:50]
super().init(**kwargs)
self.set_transient_for(window)

    # common variables and references
    self.window = window
    self.manager = window.manager
    self.config = config

    # connect signals (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.installer:[99:105]
==bottles.frontend.windows.vmtouch:[34:43]
super().init(**kwargs)
self.set_transient_for(window)

    # common variables and references
    self.window = window
    self.manager = window.manager
    self.config = config

    # connect signals (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.windows.display:[49:56]
==bottles.frontend.windows.vkbasalt:[81:88]
super().init(**kwargs)
self.set_transient_for(parent_window)

    # Common variables and references
    self.window = parent_window
    self.manager = parent_window.manager
    self.config = config (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.bottle_installers:[80:91]
==bottles.frontend.views.bottle_versioning:[65:77]
for r in self.__registry:
if r.get_parent() is not None:
r.get_parent().remove(r)
self.__registry = []

@GtkUtils.run_in_main_loop
def update(self, widget=None, config=None, states=None, active=0):
    """
    This function update the states list with the
    ones from the bottle configuration.
    """
    if config is None: (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.bottle_dependencies:[49:57]
==bottles.frontend.views.bottle_preferences:[123:130]
super().init(**kwargs)

    # common variables and references
    self.window = details.window
    self.manager = details.window.manager
    self.config = config
    self.queue = details.queue (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0801: Similar lines in 2 files
==bottles.frontend.views.list:[45:56]
==bottles.frontend.widgets.dependency:[43:54]
spinner = Gtk.Template.Child()

# endregion

def __init__(self, window, config: BottleConfig, dependency, plain=False, **kwargs):
    super().__init__(**kwargs)

    # common variables and references
    self.window = window
    self.manager = window.manager
    self.config = config (duplicate-code)

bottles/tests/backend/manager/test_manager.py:1:0: R0401: Cyclic import (bottles.backend.models.config -> bottles.backend.utils.yaml) (cyclic-import)
bottles/tests/backend/manager/test_manager.py:1:0: R0401: Cyclic import (bottles.backend.utils.gpu -> bottles.backend.utils.nvidia) (cyclic-import)
bottles/tests/backend/manager/test_manager.py:1:0: R0401: Cyclic import (bottles.backend.utils.manager -> bottles.backend.wine.winepath) (cyclic-import)
bottles/tests/backend/manager/test_manager.py:1:0: R0401: Cyclic import (bottles.backend.managers.runtime -> bottles.backend.managers.steam -> bottles.backend.wine.winecommand) (cyclic-import)
bottles/tests/backend/manager/test_manager.py:1:0: R0401: Cyclic import (bottles.backend.utils.manager -> bottles.backend.wine.winepath -> bottles.backend.wine.wineprogram -> bottles.backend.wine.winecommand) (cyclic-import)
bottles/tests/backend/manager/test_manager.py:1:0: R0401: Cyclic import (bottles.backend.managers.runtime -> bottles.backend.managers.steam -> bottles.backend.utils.manager -> bottles.backend.wine.winepath -> bottles.backend.wine.wineprogram -> bottles.backend.wine.winecommand) (cyclic-import)


Your code has been rated at 4.22/10

@StoneMoe StoneMoe marked this pull request as ready for review February 27, 2023 07:13
@StoneMoe StoneMoe marked this pull request as draft March 7, 2023 09:26
Copy link
Member

@mirkobrombin mirkobrombin left a comment

Choose a reason for hiding this comment

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

Looks good to me. This is a draft but looks complete. Am I wrong?

@StoneMoe
Copy link
Contributor Author

StoneMoe commented Apr 3, 2023

Looks good to me. This is a draft but looks complete. Am I wrong?

this bug regress multiple times, so I want to make sure it's properly fixed.
there is a known issue about incorrect encoding detection in this PR, still working on it.

@StoneMoe StoneMoe marked this pull request as ready for review April 4, 2023 05:58
@StoneMoe
Copy link
Contributor Author

StoneMoe commented Apr 4, 2023

I think it's ready for review now.

Copy link
Member

@mirkobrombin mirkobrombin left a comment

Choose a reason for hiding this comment

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

LGTM

@Kinsteen Kinsteen added this to the 52.0 milestone Apr 26, 2023
# Conflicts:
#	bottles/backend/utils/generic.py
#	bottles/backend/wine/executor.py
#	bottles/backend/wine/winecommand.py
@Kinsteen Kinsteen merged commit de8338e into bottlesdevs:main May 4, 2023
4 checks passed
@StoneMoe StoneMoe deleted the fix-winecommand branch May 4, 2023 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants