wistful / SublimeAutoPEP8

Automatically formats Python code to conform to the PEP 8 style guide using autopep8 and pep8 modules
144 stars 23 forks source link

Initial support for ST3. Fix issue #14 #15

Closed dnatag closed 11 years ago

dnatag commented 11 years ago

Tested on MacOSX.

wistful commented 11 years ago

Have you tested this with both ST2 and ST3?

dnatag commented 11 years ago

I just added the backward compatible to ST2

On Saturday, March 23, 2013 at 5:59 PM, Mikhail wrote:

Have you tested this with both ST2 and ST3?

— Reply to this email directly or view it on GitHub (https://github.com/wistful/SublimeAutoPEP8/pull/15#issuecomment-15346565).

wistful commented 11 years ago

autopep8 = __import__('sublimeautopep8lib.autopep8') returns the top-level package (the name up till the first dot) when an empty fromlist argument is given. http://docs.python.org/3.3/library/functions.html?#__import__

dnatag4snippet commented 11 years ago

Admitted I did not read the doc, which I should. I made changes to avoid the top-level import. Does it work for you in this case? It seems OSX ST3 works without top-level import issue even before this.

On Sunday, March 24, 2013 at 9:13 AM, Mikhail wrote:

autopep8 = import('sublimeautopep8lib.autopep8') returns the top-level package (the name up till the first dot) when an empty fromlist argument is given.
http://docs.python.org/3.3/library/functions.html?#__import__

— Reply to this email directly or view it on GitHub (https://github.com/wistful/SublimeAutoPEP8/pull/15#issuecomment-15358527).

wistful commented 11 years ago

Thank you for your changes. Works fine with ST2. Unfortunately I can't check it on ST3.