jarvisteach/appJar

View on GitHub
appJar/lib/nanojpeg.py

Summary

Maintainability
F
2 wks
Test Coverage

File nanojpeg.py has 582 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import array, sys
# NanoJPEG -- KeyJ's Tiny Baseline JPEG Decoder
# version 1.1 (2010-03-05)
# by Martin J. Fiedler <martin.fiedler@gmx.net>
# http://keyj.emphy.de/nanojpeg/
Severity: Major
Found in appJar/lib/nanojpeg.py - About 1 day to fix

    Function njDecodeScan has a Cognitive Complexity of 40 (exceeds 5 allowed). Consider refactoring.
    Open

    def njDecodeScan():
        rstcount = nj.rstinterval
        nextrst = 0
        # nj_component_t* c;
        njDecodeLength()
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 6 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function njConvert has a Cognitive Complexity of 38 (exceeds 5 allowed). Consider refactoring.
    Open

    def njConvert():
        for i in range(nj.ncomp):
            c = nj.comp[i]
            if NJ_CHROMA_FILTER:
                while ((c.width < nj.width) or (c.height < nj.height)):
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 5 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Cyclomatic complexity is too high in function njDecodeScan. (21)
    Open

    def njDecodeScan():
        rstcount = nj.rstinterval
        nextrst = 0
        # nj_component_t* c;
        njDecodeLength()
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Cyclomatic complexity is too high in function njDecodeSOF. (20)
    Open

    def njDecodeSOF():
        ssxmax = 0
        ssymax = 0
        njDecodeLength()
        if (nj.length < 9):
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Function njDecodeDHT has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
    Open

    def njDecodeDHT():
        counts = [0] * 16
        njDecodeLength()
        while (nj.length >= 17):
            i = nj.spos[nj.pos]
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 4 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function njDecodeSOF has a Cognitive Complexity of 27 (exceeds 5 allowed). Consider refactoring.
    Open

    def njDecodeSOF():
        ssxmax = 0
        ssymax = 0
        njDecodeLength()
        if (nj.length < 9):
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 3 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Cyclomatic complexity is too high in function njConvert. (17)
    Open

    def njConvert():
        for i in range(nj.ncomp):
            c = nj.comp[i]
            if NJ_CHROMA_FILTER:
                while ((c.width < nj.width) or (c.height < nj.height)):
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Cyclomatic complexity is too high in function njDecode. (14)
    Open

    def njDecode(jpeg, size):
        njDone()
        nj.spos = jpeg
        nj.pos = 0
        nj.size = size & 0x7FFFFFFF
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Cyclomatic complexity is too high in function njDecodeDHT. (13)
    Open

    def njDecodeDHT():
        counts = [0] * 16
        njDecodeLength()
        while (nj.length >= 17):
            i = nj.spos[nj.pos]
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Function njShowBits has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
    Open

    def njShowBits(bits):
        if (not bits): return 0
        while (nj.bufbits < bits):
            if (nj.size <= 0):
                nj.buf = (nj.buf << 8) | 0xFF
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 2 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Cyclomatic complexity is too high in function njDecodeBlock. (10)
    Open

    def njDecodeBlock(c, sout, out):
        code = [0]
        value = 0
        coef = 0
        for i in range(len(nj.block)):
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Cyclomatic complexity is too high in function njShowBits. (9)
    Open

    def njShowBits(bits):
        if (not bits): return 0
        while (nj.bufbits < bits):
            if (nj.size <= 0):
                nj.buf = (nj.buf << 8) | 0xFF
    Severity: Minor
    Found in appJar/lib/nanojpeg.py by radon

    Cyclomatic Complexity

    Cyclomatic Complexity corresponds to the number of decisions a block of code contains plus 1. This number (also called McCabe number) is equal to the number of linearly independent paths through the code. This number can be used as a guide when testing conditional logic in blocks.

    Radon analyzes the AST tree of a Python program to compute Cyclomatic Complexity. Statements have the following effects on Cyclomatic Complexity:

    Construct Effect on CC Reasoning
    if +1 An if statement is a single decision.
    elif +1 The elif statement adds another decision.
    else +0 The else statement does not cause a new decision. The decision is at the if.
    for +1 There is a decision at the start of the loop.
    while +1 There is a decision at the while statement.
    except +1 Each except branch adds a new conditional path of execution.
    finally +0 The finally block is unconditionally executed.
    with +1 The with statement roughly corresponds to a try/except block (see PEP 343 for details).
    assert +1 The assert statement internally roughly equals a conditional statement.
    Comprehension +1 A list/set/dict comprehension of generator expression is equivalent to a for loop.
    Boolean Operator +1 Every boolean operator (and, or) adds a decision point.

    Source: http://radon.readthedocs.org/en/latest/intro.html

    Function njDecode has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
    Open

    def njDecode(jpeg, size):
        njDone()
        nj.spos = jpeg
        nj.pos = 0
        nj.size = size & 0x7FFFFFFF
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 2 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function njColIDCT has 45 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    def njColIDCT(blk, p, sout, out, stride):
        x1 = blk[p + 8*4] << 8
        x2 = blk[p + 8*6]
        x3 = blk[p + 8*2]
        x4 = blk[p + 8*1]
    Severity: Minor
    Found in appJar/lib/nanojpeg.py - About 1 hr to fix

      Function njDecodeBlock has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
      Open

      def njDecodeBlock(c, sout, out):
          code = [0]
          value = 0
          coef = 0
          for i in range(len(nj.block)):
      Severity: Minor
      Found in appJar/lib/nanojpeg.py - About 1 hr to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Function njRowIDCT has 38 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      def njRowIDCT(blk, p):
          x1 = blk[p + 4] << 11
          x2 = blk[p + 6]
          x3 = blk[p + 2]
          x4 = blk[p + 1]
      Severity: Minor
      Found in appJar/lib/nanojpeg.py - About 1 hr to fix

        Avoid deeply nested control flow statements.
        Open

                            if ((marker & 0xF8) != 0xD0):
                                raise Exception(NJ_SYNTAX_ERROR)
                            else:
                                nj.buf = (nj.buf << 8) | marker
                                nj.bufbits += 8
        Severity: Major
        Found in appJar/lib/nanojpeg.py - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                              if nj.error:
                                  return
                              sbx += 1
          Severity: Major
          Found in appJar/lib/nanojpeg.py - About 45 mins to fix

            Function njColIDCT has 5 arguments (exceeds 4 allowed). Consider refactoring.
            Open

            def njColIDCT(blk, p, sout, out, stride):
            Severity: Minor
            Found in appJar/lib/nanojpeg.py - About 35 mins to fix

              Avoid too many return statements within this function.
              Open

                  if (nj.error != __NJ_FINISHED): return nj.error
              Severity: Major
              Found in appJar/lib/nanojpeg.py - About 30 mins to fix

                Avoid too many return statements within this function.
                Open

                    return nj.error
                Severity: Major
                Found in appJar/lib/nanojpeg.py - About 30 mins to fix

                  Function njDecodeDQT has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                  Open

                  def njDecodeDQT():
                      njDecodeLength()
                      while (nj.length >= 65):
                          i = nj.spos[nj.pos]
                          if (i & 0xFC):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py - About 25 mins to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                              out[lout + (x << 1) + 4] = CF(CF4D * c.pixels[lin + x] + CF4C * c.pixels[lin + x + 1] + CF4B * c.pixels[lin + x + 2] + CF4A * c.pixels[lin + x + 3])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 1 day to fix
                  appJar/lib/nanojpeg.py on lines 766..766

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 149.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                              out[lout + (x << 1) + 3] = CF(CF4A * c.pixels[lin + x] + CF4B * c.pixels[lin + x + 1] + CF4C * c.pixels[lin + x + 2] + CF4D * c.pixels[lin + x + 3])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 1 day to fix
                  appJar/lib/nanojpeg.py on lines 767..767

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 149.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                              out[cout] = CF(CF4D * c.pixels[cin - s1] + CF4C * c.pixels[cin] + CF4B * c.pixels[cin + s1] + CF4A * c.pixels[cin + s2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 6 hrs to fix
                  appJar/lib/nanojpeg.py on lines 795..795

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 107.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                              out[cout] = CF(CF4A * c.pixels[cin - s1] + CF4B * c.pixels[cin] + CF4C * c.pixels[cin + s1] + CF4D * c.pixels[cin + s2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 6 hrs to fix
                  appJar/lib/nanojpeg.py on lines 797..797

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 107.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[lout + 1] = CF(CF3X * c.pixels[lin + 0] + CF3Y * c.pixels[lin + 1] + CF3Z * c.pixels[lin + 2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 5 hrs to fix
                  appJar/lib/nanojpeg.py on lines 764..764

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 93.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[lout + 2] = CF(CF3A * c.pixels[lin + 0] + CF3B * c.pixels[lin + 1] + CF3C * c.pixels[lin + 2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 5 hrs to fix
                  appJar/lib/nanojpeg.py on lines 763..763

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 93.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[lout - 2] = CF(CF3X * c.pixels[lin - 1] + CF3Y * c.pixels[lin - 2] + CF3Z * c.pixels[lin - 3])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 5 hrs to fix
                  appJar/lib/nanojpeg.py on lines 770..770

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 93.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[lout - 3] = CF(CF3A * c.pixels[lin - 1] + CF3B * c.pixels[lin - 2] + CF3C * c.pixels[lin - 3])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 5 hrs to fix
                  appJar/lib/nanojpeg.py on lines 771..771

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 93.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[cout] = CF(CF3X * c.pixels[cin] + CF3Y * c.pixels[cin + s1] + CF3Z * c.pixels[cin + s2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 4 hrs to fix
                  appJar/lib/nanojpeg.py on lines 790..790

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 81.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[cout] = CF(CF3A * c.pixels[cin] + CF3B * c.pixels[cin - s1] + CF3C * c.pixels[cin - s2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 4 hrs to fix
                  appJar/lib/nanojpeg.py on lines 804..804

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 81.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[cout] = CF(CF3A * c.pixels[cin] + CF3B * c.pixels[cin + s1] + CF3C * c.pixels[cin + s2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 4 hrs to fix
                  appJar/lib/nanojpeg.py on lines 788..788

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 81.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          out[cout] = CF(CF3X * c.pixels[cin] + CF3Y * c.pixels[cin - s1] + CF3Z * c.pixels[cin - s2])
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 4 hrs to fix
                  appJar/lib/nanojpeg.py on lines 802..802

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 81.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Identical blocks of code found in 2 locations. Consider refactoring.
                  Open

                      if (not (x1 | x2 | x3 | x4 | x5 | x6 | x7)):
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 1 hr to fix
                  appJar/lib/nanojpeg.py on lines 350..350

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 41.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Identical blocks of code found in 2 locations. Consider refactoring.
                  Open

                      if (not (x1 | x2 | x3 | x4 | x5 | x6 | x7)):
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 1 hr to fix
                  appJar/lib/nanojpeg.py on lines 404..404

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 41.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                                  nj.rgb[prgb] = njClip((y            + 359 * cr + 128) >> 8)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 1 hr to fix
                  appJar/lib/nanojpeg.py on lines 872..872

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 41.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                                  nj.rgb[prgb] = njClip((y + 454 * cb            + 128) >> 8)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 1 hr to fix
                  appJar/lib/nanojpeg.py on lines 868..868

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 41.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          c.height = (nj.height * c.ssy + ssymax - 1) // ssymax
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 45 mins to fix
                  appJar/lib/nanojpeg.py on lines 563..563

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 35.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                          c.width = (nj.width * c.ssx + ssxmax - 1) // ssxmax
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 45 mins to fix
                  appJar/lib/nanojpeg.py on lines 566..566

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 35.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x3 + x2) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 435..435
                  appJar/lib/nanojpeg.py on lines 439..439
                  appJar/lib/nanojpeg.py on lines 441..441

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x0 - x4) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 443..443
                  appJar/lib/nanojpeg.py on lines 447..447
                  appJar/lib/nanojpeg.py on lines 449..449

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x3 - x2) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 443..443
                  appJar/lib/nanojpeg.py on lines 445..445
                  appJar/lib/nanojpeg.py on lines 449..449

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x8 - x6) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 445..445
                  appJar/lib/nanojpeg.py on lines 447..447
                  appJar/lib/nanojpeg.py on lines 449..449

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x0 + x4) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 435..435
                  appJar/lib/nanojpeg.py on lines 437..437
                  appJar/lib/nanojpeg.py on lines 441..441

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x7 - x1) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 443..443
                  appJar/lib/nanojpeg.py on lines 445..445
                  appJar/lib/nanojpeg.py on lines 447..447

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x7 + x1) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 437..437
                  appJar/lib/nanojpeg.py on lines 439..439
                  appJar/lib/nanojpeg.py on lines 441..441

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 4 locations. Consider refactoring.
                  Open

                      sout[out] = njClip(((x8 + x6) >> 14) + 128)
                  Severity: Major
                  Found in appJar/lib/nanojpeg.py and 3 other locations - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 435..435
                  appJar/lib/nanojpeg.py on lines 437..437
                  appJar/lib/nanojpeg.py on lines 439..439

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                                  cb = nj.comp[1].pixels[pcb + x] - 128
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 867..867

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                                  cr = nj.comp[2].pixels[pcr + x] - 128
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py and 1 other location - About 35 mins to fix
                  appJar/lib/nanojpeg.py on lines 866..866

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 33.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Too many leading '#' for block comment
                  Open

                  ## EXAMPLE PROGRAM                                                           ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Too many leading '#' for block comment
                  Open

                  ## you may stop reading here                                                 ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Multiple statements on one line (colon)
                  Open

                      if x > 0xFF: return 0xFF
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple statements on one line (colon)
                  Open

                          if (c.ssx > ssxmax): ssxmax = c.ssx
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  At least two spaces before inline comment
                  Open

                          for codelen in range(1, 17): # 1 to 16
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  At least two spaces before inline comment
                  Open

                  NJ_SYNTAX_ERROR = 5 # syntax error
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Multiple statements on one line (colon)
                  Open

                      if (not bits): return 0
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 1
                  Open

                  def njDecode16(pos):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                          if not code[0]: break  # EOB
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Too many leading '#' for block comment
                  Open

                  ## copy and pase this into nanojpeg.h if you want                            ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Whitespace before ']'
                  Open

                      38, 31, 39, 46, 53, 60, 61, 54, 47, 55, 62, 63 ]
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Avoid extraneous whitespace.

                  Avoid extraneous whitespace in these situations:
                  - Immediately inside parentheses, brackets or braces.
                  - Immediately before a comma, semicolon, or colon.
                  
                  Okay: spam(ham[1], {eggs: 2})
                  E201: spam( ham[1], {eggs: 2})
                  E201: spam(ham[ 1], {eggs: 2})
                  E201: spam(ham[1], { eggs: 2})
                  E202: spam(ham[1], {eggs: 2} )
                  E202: spam(ham[1 ], {eggs: 2})
                  E202: spam(ham[1], {eggs: 2 })
                  
                  E203: if x == 4: print x, y; x, y = y , x
                  E203: if x == 4: print x, y ; x, y = y, x
                  E203: if x == 4 : print x, y; x, y = y, x

                  Multiple statements on one line (colon)
                  Open

                      if x < 0: return 0
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 1
                  Open

                  def njByteAlign():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                          elif m == 0xDD: njDecodeDRI()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple statements on one line (colon)
                  Open

                      if (nj.error != __NJ_FINISHED): return nj.error
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Over-indented
                  Open

                                  raise Exception(NJ_UNSUPPORTED)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Use indent_size (PEP8 says 4) spaces per indentation level.

                  For really old code that you don't want to mess up, you can continue
                  to use 8-space tabs.
                  
                  Okay: a = 1
                  Okay: if a == 0:\n    a = 1
                  E111:   a = 1
                  E114:   # a = 1
                  
                  Okay: for item in items:\n    pass
                  E112: for item in items:\npass
                  E115: for item in items:\n# Hi\n    pass
                  
                  Okay: a = 1\nb = 2
                  E113: a = 1\n    b = 2
                  E116: a = 1\n    # b = 2

                  Multiple statements on one line (colon)
                  Open

                                  if nj.error: return
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple spaces before operator
                  Open

                          py  = 0
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Avoid extraneous whitespace around an operator.

                  Okay: a = 12 + 3
                  E221: a = 4  + 5
                  E222: a = 4 +  5
                  E223: a = 4\t+ 5
                  E224: a = 4 +\t5

                  Multiple statements on one line (colon)
                  Open

                              if mby >= nj.mbheight: break
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 1
                  Open

                  def njDecode(jpeg, size):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                      if (nj.size < 2): return NJ_NO_JPEG
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple statements on one line (colon)
                  Open

                      if ((nj.spos[nj.pos] ^ 0xFF) | (nj.spos[nj.pos + 1] ^ 0xD8)): return NJ_NO_JPEG
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Too many leading '#' for block comment
                  Open

                  ## just define _NJ_EXAMPLE_PROGRAM to compile this (requires NJ_USE_LIBC)    ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  At least two spaces before inline comment
                  Open

                          self.spos = None # new param. it stores the string what is indexed by pos
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Expected 2 blank lines, found 1
                  Open

                  def njGetBits(bits):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeLength():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                      if code: code[0] = value
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Statement ends with a semicolon
                  Open

                          value = njGetVLC(nj.vlctab[c.actabsel], code);
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple statements on one line (colon)
                  Open

                                  if c.height < nj.height: njUpsampleV(c)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 1
                  Open

                  def njDone():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 0
                  Open

                  def njGetImageSize():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple imports on one line
                  Open

                  import array, sys
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Place imports on separate lines.

                  Okay: import os\nimport sys
                  E401: import sys, os
                  
                  Okay: from subprocess import Popen, PIPE
                  Okay: from myclas import MyClass
                  Okay: from foo.bar.yourclass import YourClass
                  Okay: import myclass
                  Okay: import foo.bar.yourclass

                  Missing whitespace around operator
                  Open

                          self.ssy= 0
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Surround operators with a single space on either side.

                  - Always surround these binary operators with a single space on
                    either side: assignment (=), augmented assignment (+=, -= etc.),
                    comparisons (==, <, >, !=, <=, >=, in, not in, is, is not),
                    Booleans (and, or, not).
                  
                  - If operators with different priorities are used, consider adding
                    whitespace around the operators with the lowest priorities.
                  
                  Okay: i = i + 1
                  Okay: submitted += 1
                  Okay: x = x * 2 - 1
                  Okay: hypot2 = x * x + y * y
                  Okay: c = (a + b) * (a - b)
                  Okay: foo(bar, key='word', *args, **kwargs)
                  Okay: alpha[:-i]
                  
                  E225: i=i+1
                  E225: submitted +=1
                  E225: x = x /2 - 1
                  E225: z = x **y
                  E225: z = 1and 1
                  E226: c = (a+b) * (a-b)
                  E226: hypot2 = x*x + y*y
                  E227: c = a|b
                  E228: msg = fmt%(errno, errmsg)

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeSOF():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple spaces after operator
                  Open

                                  nj.rgb[prgb] = njClip((y -  88 * cb - 183 * cr + 128) >> 8)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Avoid extraneous whitespace around an operator.

                  Okay: a = 12 + 3
                  E221: a = 4  + 5
                  E222: a = 4 +  5
                  E223: a = 4\t+ 5
                  E224: a = 4 +\t5

                  Expected 2 blank lines after class or function definition, found 1
                  Open

                  nj = nj_context_t()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines after class or function definition, found 1
                  Open

                  W1 = 2841
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeDHT():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 0
                  Open

                  def njGetImage():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Whitespace after '['
                  Open

                  njZZ = [ 0, 1, 8, 16, 9, 2, 3, 10, 17, 24, 32, 25, 18,
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Avoid extraneous whitespace.

                  Avoid extraneous whitespace in these situations:
                  - Immediately inside parentheses, brackets or braces.
                  - Immediately before a comma, semicolon, or colon.
                  
                  Okay: spam(ham[1], {eggs: 2})
                  E201: spam( ham[1], {eggs: 2})
                  E201: spam(ham[ 1], {eggs: 2})
                  E201: spam(ham[1], { eggs: 2})
                  E202: spam(ham[1], {eggs: 2} )
                  E202: spam(ham[1 ], {eggs: 2})
                  E202: spam(ham[1], {eggs: 2 })
                  
                  E203: if x == 4: print x, y; x, y = y , x
                  E203: if x == 4: print x, y ; x, y = y, x
                  E203: if x == 4 : print x, y; x, y = y, x

                  Expected 2 blank lines, found 1
                  Open

                  def njClip(x):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njSkipBits(bits):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 0
                  Open

                  def CF(x):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njUpsampleH(c):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 0
                  Open

                  def njIsColor():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  class nj_component_t(object):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                      if (nj.size < 0): raise Exception(NJ_SYNTAX_ERROR)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 1
                  Open

                  def njSkipMarker():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                      if not bits: return 0
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Too many leading '#' for block comment
                  Open

                  ## read this if you want to know what this is all about                      ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Expected 2 blank lines, found 1
                  Open

                  def njRowIDCT(blk, p):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeDRI():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeBlock(c, sout, out):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  At least two spaces before inline comment
                  Open

                          for codelen in range(1, 17): # 1 to 16
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Expected 2 blank lines, found 1
                  Open

                  def njGetVLC(vlc, code):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                          if coef >= 63: break
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines after class or function definition, found 1
                  Open

                  CF4A = -9
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                          if m == 0xC0: njDecodeSOF()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple statements on one line (colon)
                  Open

                          elif m == 0xDA: njDecodeScan()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Too many leading '#' for block comment
                  Open

                  ## DOCUMENTATION SECTION                                                     ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Continuation line under-indented for visual indent
                  Open

                      11, 4, 5, 12, 19, 26, 33, 40, 48, 41, 34, 27, 20, 13, 6, 7, 14, 21, 28, 35,
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Continuation lines indentation.

                  Continuation lines should align wrapped elements either vertically
                  using Python's implicit line joining inside parentheses, brackets
                  and braces, or using a hanging indent.
                  
                  When using a hanging indent these considerations should be applied:
                  - there should be no arguments on the first line, and
                  - further indentation should be used to clearly distinguish itself
                    as a continuation line.
                  
                  Okay: a = (\n)
                  E123: a = (\n    )
                  
                  Okay: a = (\n    42)
                  E121: a = (\n   42)
                  E122: a = (\n42)
                  E123: a = (\n    42\n    )
                  E124: a = (24,\n     42\n)
                  E125: if (\n    b):\n    pass
                  E126: a = (\n        42)
                  E127: a = (24,\n      42)
                  E128: a = (24,\n    42)
                  E129: if (a or\n    b):\n    pass
                  E131: a = (\n    42\n 24)

                  Continuation line under-indented for visual indent
                  Open

                      42, 49, 56, 57, 50, 43, 36, 29, 22, 15, 23, 30, 37, 44, 51, 58, 59, 52, 45,
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Continuation lines indentation.

                  Continuation lines should align wrapped elements either vertically
                  using Python's implicit line joining inside parentheses, brackets
                  and braces, or using a hanging indent.
                  
                  When using a hanging indent these considerations should be applied:
                  - there should be no arguments on the first line, and
                  - further indentation should be used to clearly distinguish itself
                    as a continuation line.
                  
                  Okay: a = (\n)
                  E123: a = (\n    )
                  
                  Okay: a = (\n    42)
                  E121: a = (\n   42)
                  E122: a = (\n42)
                  E123: a = (\n    42\n    )
                  E124: a = (24,\n     42\n)
                  E125: if (\n    b):\n    pass
                  E126: a = (\n        42)
                  E127: a = (24,\n      42)
                  E128: a = (24,\n    42)
                  E129: if (a or\n    b):\n    pass
                  E131: a = (\n    42\n 24)

                  Expected 2 blank lines, found 1
                  Open

                  def njSkip(count):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  At least two spaces before inline comment
                  Open

                      while True: # do {
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Multiple statements on one line (colon)
                  Open

                                  if c.width < nj.width: njUpsampleH(c)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  At least two spaces before inline comment
                  Open

                  NJ_INTERNAL_ERR = 4 # internal error
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Multiple spaces before operator
                  Open

                                  nj.rgb[prgb] = njClip((y + 454 * cb            + 128) >> 8)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Avoid extraneous whitespace around an operator.

                  Okay: a = 12 + 3
                  E221: a = 4  + 5
                  E222: a = 4 +  5
                  E223: a = 4\t+ 5
                  E224: a = 4 +\t5

                  Expected 2 blank lines, found 1
                  Open

                  def njInit():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                          if (c.ssy > ssymax): ssymax = c.ssy
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple statements on one line (colon)
                  Open

                          elif m == 0xC4: njDecodeDHT()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeDQT():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                          elif m == 0xDB: njDecodeDQT()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Expected 2 blank lines, found 0
                  Open

                  def njGetHeight():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Too many leading '#' for block comment
                  Open

                  ## HEADER SECTION                                                            ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Too many leading '#' for block comment
                  Open

                  ## CONFIGURATION SECTION                                                     ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Too many leading '#' for block comment
                  Open

                  ## adjust the default settings for the NJ_ defines here                      ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Expected 2 blank lines, found 1
                  Open

                  class nj_context_t(object):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Continuation line under-indented for visual indent
                  Open

                      38, 31, 39, 46, 53, 60, 61, 54, 47, 55, 62, 63 ]
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Continuation lines indentation.

                  Continuation lines should align wrapped elements either vertically
                  using Python's implicit line joining inside parentheses, brackets
                  and braces, or using a hanging indent.
                  
                  When using a hanging indent these considerations should be applied:
                  - there should be no arguments on the first line, and
                  - further indentation should be used to clearly distinguish itself
                    as a continuation line.
                  
                  Okay: a = (\n)
                  E123: a = (\n    )
                  
                  Okay: a = (\n    42)
                  E121: a = (\n   42)
                  E122: a = (\n42)
                  E123: a = (\n    42\n    )
                  E124: a = (24,\n     42\n)
                  E125: if (\n    b):\n    pass
                  E126: a = (\n        42)
                  E127: a = (24,\n      42)
                  E128: a = (24,\n    42)
                  E129: if (a or\n    b):\n    pass
                  E131: a = (\n    42\n 24)

                  Multiple statements on one line (colon)
                  Open

                              if not currcnt: continue
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Multiple spaces before operator
                  Open

                                  nj.rgb[prgb] = njClip((y            + 359 * cr + 128) >> 8)
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Avoid extraneous whitespace around an operator.

                  Okay: a = 12 + 3
                  E221: a = 4  + 5
                  E222: a = 4 +  5
                  E223: a = 4\t+ 5
                  E224: a = 4 +\t5

                  Multiple statements on one line (colon)
                  Open

                          elif m == 0xFE: njSkipMarker()
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  Too many leading '#' for block comment
                  Open

                  ## IMPLEMENTATION SECTION                                                    ##
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate inline comments by at least two spaces.

                  An inline comment is a comment on the same line as a statement.
                  Inline comments should be separated by at least two spaces from the
                  statement. They should start with a # and a single space.
                  
                  Each line of a block comment starts with a # and a single space
                  (unless it is indented text inside the comment).
                  
                  Okay: x = x + 1  # Increment x
                  Okay: x = x + 1    # Increment x
                  Okay: # Block comment
                  E261: x = x + 1 # Increment x
                  E262: x = x + 1  #Increment x
                  E262: x = x + 1  #  Increment x
                  E265: #Block comment
                  E266: ### Block comment

                  Expected 2 blank lines, found 1
                  Open

                  def njDecodeScan():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njUpsampleV(c):
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Expected 2 blank lines, found 1
                  Open

                  def njConvert():
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Separate top-level function and class definitions with two blank lines.

                  Method definitions inside a class are separated by a single blank
                  line.
                  
                  Extra blank lines may be used (sparingly) to separate groups of
                  related functions.  Blank lines may be omitted between a bunch of
                  related one-liners (e.g. a set of dummy implementations).
                  
                  Use blank lines in functions, sparingly, to indicate logical
                  sections.
                  
                  Okay: def a():\n    pass\n\n\ndef b():\n    pass
                  Okay: def a():\n    pass\n\n\nasync def b():\n    pass
                  Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
                  Okay: default = 1\nfoo = 1
                  Okay: classify = 1\nfoo = 1
                  
                  E301: class Foo:\n    b = 0\n    def bar():\n        pass
                  E302: def a():\n    pass\n\ndef b(n):\n    pass
                  E302: def a():\n    pass\n\nasync def b(n):\n    pass
                  E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
                  E303: def a():\n\n\n\n    pass
                  E304: @decorator\n\ndef a():\n    pass
                  E305: def a():\n    pass\na()
                  E306: def a():\n    def b():\n        pass\n    def c():\n        pass

                  Multiple statements on one line (colon)
                  Open

                                  if nj.error: return
                  Severity: Minor
                  Found in appJar/lib/nanojpeg.py by pep8

                  Compound statements (on the same line) are generally discouraged.

                  While sometimes it's okay to put an if/for/while with a small body
                  on the same line, never do this for multi-clause statements.
                  Also avoid folding such long lines!
                  
                  Always use a def statement instead of an assignment statement that
                  binds a lambda expression directly to a name.
                  
                  Okay: if foo == 'blah':\n    do_blah_thing()
                  Okay: do_one()
                  Okay: do_two()
                  Okay: do_three()
                  
                  E701: if foo == 'blah': do_blah_thing()
                  E701: for x in lst: total += x
                  E701: while t < 10: t = delay()
                  E701: if foo == 'blah': do_blah_thing()
                  E701: else: do_non_blah_thing()
                  E701: try: something()
                  E701: finally: cleanup()
                  E701: if foo == 'blah': one(); two(); three()
                  E702: do_one(); do_two(); do_three()
                  E703: do_four();  # useless semicolon
                  E704: def f(x): return 2*x
                  E731: f = lambda x: 2*x

                  There are no issues that match your filters.

                  Category
                  Status