Skip to content

Conversation

@bfi-bot
Copy link

@bfi-bot bfi-bot commented May 30, 2025

This PR was automatically created from branch: branch_test

@bfi-bot
Copy link
Author

bfi-bot commented May 30, 2025

Automated Pylint Report 🧑‍💻

Here is the formatted Pylint report:

************* Module checksum_speed_test_crontab
checksum_speed_test_crontab.py:56:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:71:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:89:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:104:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:108:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
checksum_speed_test_crontab.py:117:62: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:119:62: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:121:64: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:123:64: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:111:22: ⚠️ W0612: Unused variable 'dirs' (unused-variable)
************* Module checksum_speed_test
checksum_speed_test.py:107:0: 🎨 C0301: Line too long (127/100) (line-too-long)
checksum_speed_test.py:110:0: 🎨 C0325: Unnecessary parens after 'not' keyword (superfluous-parens)
checksum_speed_test.py:50:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test.py:66:4: ⚠️ W0711: Exception to catch is the result of a binary "and" operation (binary-op-exception)
checksum_speed_test.py:66:25: 🚨 E0602: Undefined variable 'err' (undefined-variable)
checksum_speed_test.py:67:14: 🚨 E0602: Undefined variable 'err' (undefined-variable)
checksum_speed_test.py:85:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test.py:101:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test.py:105:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
checksum_speed_test.py:115:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:119:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:123:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:128:16: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:133:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
************* Module test_checksum_speed_test
test_checksum_speed_test.py:8:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:13:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:18:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:23:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:28:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:33:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:38:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:43:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[136:164]
==checksum_speed_test_crontab:[123:151]
                    logger.info(
                        "%s\t CRC32 4096\t %s\t %s\t Python <version>",
                        filepath,
                        size_mb,
                        crc_time,
                    )
                    logger.info(
                        "%s\t MD5 4096\t %s\t %s\t Python <version>",
                        filepath,
                        size_mb,
                        md5_time,
                    )
                    logger.info(
                        "%s\t CRC32 65536\t %s\t %s\t Python <version>",
                        filepath,
                        size_mb,
                        crc2_time,
                    )
                    logger.info(
                        "%s\t MD5 65536\t %s\t %s\t Python <version>",
                        filepath,
                        size_mb,
                        md52_time,
                    )


if __name__ == "__main__":
    main() (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[86:105]
==checksum_speed_test_crontab:[89:108]
        return None


def md5_65536(file):
    """
    Hashlib code
    """
    try:
        hash_md5 = hashlib.md5()
        with open(file, "rb") as fname:
            for chunk in iter(lambda: fname.read(65536), b""):
                hash_md5.update(chunk)
        return hash_md5.hexdigest()

    except Exception:
        return None


def main(): (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[39:49]
==checksum_speed_test_crontab:[45:55]
    try:
        with open(file, "rb") as afile:
            buffersize = 4096
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[67:84]
==checksum_speed_test_crontab:[71:88]
        return None


def crc_65536(file):
    """
    Zlib code
    """
    try:
        with open(file, "rb") as afile:
            buffersize = 65536
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[51:65]
==checksum_speed_test_crontab:[56:70]
        return None


def md5_4096(file):
    """
    Hashlib code
    """
    try:
        hash_md5 = hashlib.md5()
        with open(file, "rb") as fname:
            for chunk in iter(lambda: fname.read(4096), b""):
                hash_md5.update(chunk)
        return hash_md5.hexdigest()
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[42:49]
==checksum_speed_test_crontab:[81:88]
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[77:84]
==checksum_speed_test_crontab:[48:55]
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)

-----------------------------------
Your code has been rated at 7.42/10

Note: 🚨 Errors need immediate attention! ⚠️ Warnings should be reviewed, but are less critical. ℹ️ Information messages are for your reference.

@bfi-bot
Copy link
Author

bfi-bot commented May 30, 2025

Automated Pylint Report 🧑‍💻

Here is the formatted Pylint report:

************* Module checksum_speed_test_crontab
checksum_speed_test_crontab.py:56:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:71:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:89:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:104:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test_crontab.py:108:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
checksum_speed_test_crontab.py:117:62: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:119:62: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:121:64: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:123:64: ⚠️ W0640: Cell variable filepath defined in loop (cell-var-from-loop)
checksum_speed_test_crontab.py:111:22: ⚠️ W0612: Unused variable 'dirs' (unused-variable)
************* Module checksum_speed_test
checksum_speed_test.py:107:0: 🎨 C0301: Line too long (127/100) (line-too-long)
checksum_speed_test.py:110:0: 🎨 C0325: Unnecessary parens after 'not' keyword (superfluous-parens)
checksum_speed_test.py:50:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test.py:66:4: ⚠️ W0711: Exception to catch is the result of a binary "and" operation (binary-op-exception)
checksum_speed_test.py:66:25: 🚨 E0602: Undefined variable 'err' (undefined-variable)
checksum_speed_test.py:67:14: 🚨 E0602: Undefined variable 'err' (undefined-variable)
checksum_speed_test.py:85:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test.py:101:11: ⚠️ W0718: Catching too general exception Exception (broad-exception-caught)
checksum_speed_test.py:105:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
checksum_speed_test.py:115:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:119:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:123:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:128:16: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
checksum_speed_test.py:133:18: 🎨 C0209: Formatting a regular string which could be an f-string (consider-using-f-string)
************* Module test_checksum_speed_test
test_checksum_speed_test.py:8:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:13:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:18:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:23:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:28:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:33:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:38:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:43:0: 🎨 C0116: Missing function or method docstring (missing-function-docstring)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[136:164]
==checksum_speed_test_crontab:[123:151]
            logger.info(
                "%s\t CRC32 4096\t %s\t %s\t Python <version>",
                filepath,
                size_mb,
                crc_time,
            )
            logger.info(
                "%s\t MD5 4096\t %s\t %s\t Python <version>",
                filepath,
                size_mb,
                md5_time,
            )
            logger.info(
                "%s\t CRC32 65536\t %s\t %s\t Python <version>",
                filepath,
                size_mb,
                crc2_time,
            )
            logger.info(
                "%s\t MD5 65536\t %s\t %s\t Python <version>",
                filepath,
                size_mb,
                md52_time,
            )


if __name__ == "__main__":
    main() (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[86:105]
==checksum_speed_test_crontab:[89:108]
        return None


def md5_65536(file):
    """
    Hashlib code
    """
    try:
        hash_md5 = hashlib.md5()
        with open(file, "rb") as fname:
            for chunk in iter(lambda: fname.read(65536), b""):
                hash_md5.update(chunk)
        return hash_md5.hexdigest()

    except Exception:
        return None


def main(): (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[39:49]
==checksum_speed_test_crontab:[45:55]
    try:
        with open(file, "rb") as afile:
            buffersize = 4096
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[67:84]
==checksum_speed_test_crontab:[71:88]
        return None


def crc_65536(file):
    """
    Zlib code
    """
    try:
        with open(file, "rb") as afile:
            buffersize = 65536
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[51:65]
==checksum_speed_test_crontab:[56:70]
        return None


def md5_4096(file):
    """
    Hashlib code
    """
    try:
        hash_md5 = hashlib.md5()
        with open(file, "rb") as fname:
            for chunk in iter(lambda: fname.read(4096), b""):
                hash_md5.update(chunk)
        return hash_md5.hexdigest()
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[42:49]
==checksum_speed_test_crontab:[81:88]
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)
test_checksum_speed_test.py:1:0: ♻️ R0801: Similar lines in 2 files
==checksum_speed_test:[77:84]
==checksum_speed_test_crontab:[48:55]
            buffr = afile.read(buffersize)
            crcvalue = 0
            while len(buffr) > 0:
                crcvalue = zlib.crc32(buffr, crcvalue)
                buffr = afile.read(buffersize)
        return format(crcvalue & 0xFFFFFFFF, "08x")
 (duplicate-code)

-----------------------------------
Your code has been rated at 7.42/10

Note: 🚨 Errors need immediate attention! ⚠️ Warnings should be reviewed, but are less critical. ℹ️ Information messages are for your reference.

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