Giter Site home page Giter Site logo

Comments (7)

myint avatar myint commented on August 23, 2024

The correct indentation (to distinguish the parameters from the function body), would be:

def long_function_name(
        var_one, var_two, var_three,
        var_four):
    print(var_one)

The reason we end up with current output is due to pep8. It doesn't complain about the output you are getting.

from autopep8.

myint avatar myint commented on August 23, 2024

By the way, I added this to the pep8 issue list.

from autopep8.

leoliu avatar leoliu commented on August 23, 2024

Thank you for looking into this.

from autopep8.

myint avatar myint commented on August 23, 2024

See the issue on pep8's issue list.

from autopep8.

smichr avatar smichr commented on August 23, 2024

Is this only indenting the 2nd continued line for the same reason?

$ pep8 --version
1.3.3
$ ../autopep8/autopep8.py --version
autopep8: 0.8.1
$ ../autopep8/autopep8.py -r --select=E122 --diff sympy/solvers/ode.py
--- original/sympy/solvers/ode.py
+++ fixed/sympy/solvers/ode.py
@@ -1533,7 +1533,7 @@
                     for o in other:
                         b, e = o.as_base_exp()
                         if b.is_Add and \
-                        all(a.args_cnc(cset=True, warn=False)[0] & \
+                            all(a.args_cnc(cset=True, warn=False)[0] & \
                         con_set for a in b.args):
                             expr = sign(Mul(*num))*Mul._from_args(other)
                             break

from autopep8.

myint avatar myint commented on August 23, 2024

No, I think the culprit is --select=E122. If you want to only fix alignment issues, try --select=E12.

from autopep8.

myint avatar myint commented on August 23, 2024

I'm going to close this since we are doing to correct thing given pep8's output. If pep8 eventually changes to mark this case as incorrect, then autopep8 will automatically fix it.

from autopep8.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.