Skip to content

Follow-Up To #17875 #18043

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Oct 31, 2017
Merged

Conversation

jbrockmendel
Copy link
Member

flake8 cleanup

use abbreviated dtstruct conversion functions

import from the cython versions of the stdlib instead of from src/datetime.pxd where possible.

@jreback
Copy link
Contributor

jreback commented Oct 31, 2017

so obviously you are linting these with some settings. pls add those to lint.sh if some files are not fixed, that is ok, just put them in a separate list with the current options. fixing things, but not changing the tests is ok, but doesn't prevent changes to these or help others.

@jreback jreback added Code Style Code style, linting, code_checks Datetime Datetime data dtype labels Oct 31, 2017
@jbrockmendel
Copy link
Member Author

Just amended the lint.sh file. Somehow this mental image comes to mind.

@jreback
Copy link
Contributor

jreback commented Oct 31, 2017

@jbrockmendel hahah, great!

@jbrockmendel
Copy link
Member Author

One Travis env has a TestClipboard error, the other...

Linting *.pyx
pandas/_libs/algos.pyx:261:1: E265 block comment should start with '# '
pandas/_libs/algos.pyx:325:1: E265 block comment should start with '# '
pandas/_libs/algos.pyx:390:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/groupby.pyx:28:1: E265 block comment should start with '# '
pandas/_libs/hashing.pyx:96:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/hashing.pyx:111:30: E222 multiple spaces after operator
pandas/_libs/index.pyx:42:13: W503 line break before binary operator
pandas/_libs/index.pyx:125:43: E261 at least two spaces before inline comment
pandas/_libs/index.pyx:479:33: E127 continuation line over-indented for visual indent
pandas/_libs/index.pyx:486:38: E127 continuation line over-indented for visual indent
pandas/_libs/interval.pyx:44:13: W503 line break before binary operator
pandas/_libs/interval.pyx:45:13: W503 line break before binary operator
pandas/_libs/join.pyx:150:27: E127 continuation line over-indented for visual indent
pandas/_libs/parsers.pyx:141:29: E261 at least two spaces before inline comment
pandas/_libs/parsers.pyx:403:9: E265 block comment should start with '# '
pandas/_libs/parsers.pyx:522:9: E265 block comment should start with '# '
pandas/_libs/parsers.pyx:760:23: W503 line break before binary operator
pandas/_libs/parsers.pyx:813:54: E127 continuation line over-indented for visual indent
pandas/_libs/parsers.pyx:851:14: E261 at least two spaces before inline comment
pandas/_libs/parsers.pyx:1377:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/parsers.pyx:1420:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/parsers.pyx:1785:33: E127 continuation line over-indented for visual indent
pandas/_libs/parsers.pyx:1806:29: E127 continuation line over-indented for visual indent
pandas/_libs/parsers.pyx:2266:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/parsers.pyx:2365:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/period.pyx:112:1: E265 block comment should start with '# '
pandas/_libs/period.pyx:170:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/period.pyx:280:31: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:282:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:284:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:286:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:291:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:292:15: W503 line break before binary operator
pandas/_libs/period.pyx:292:38: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:294:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:296:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:298:33: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:300:34: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:302:34: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:304:34: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:732:14: E261 at least two spaces before inline comment
pandas/_libs/period.pyx:1150:25: E127 continuation line over-indented for visual indent
pandas/_libs/period.pyx:1151:25: E127 continuation line over-indented for visual indent
pandas/_libs/sparse.pyx:331:27: E261 at least two spaces before inline comment
pandas/_libs/sparse.pyx:489:18: E261 at least two spaces before inline comment
pandas/_libs/sparse.pyx:632:23: E261 at least two spaces before inline comment
pandas/_libs/window.pyx:1385:34: E127 continuation line over-indented for visual indent
pandas/_libs/lib.pyx:85:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/lib.pyx:119:1: E265 block comment should start with '# '
pandas/_libs/lib.pyx:122:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/lib.pyx:128:26: E261 at least two spaces before inline comment
pandas/_libs/lib.pyx:189:13: W503 line break before binary operator
pandas/_libs/lib.pyx:192:13: W503 line break before binary operator
pandas/_libs/lib.pyx:193:13: W503 line break before binary operator
pandas/_libs/lib.pyx:194:13: W503 line break before binary operator
pandas/_libs/lib.pyx:195:13: W503 line break before binary operator
pandas/_libs/lib.pyx:196:13: W503 line break before binary operator
pandas/_libs/lib.pyx:197:13: W503 line break before binary operator
pandas/_libs/lib.pyx:198:13: W503 line break before binary operator
pandas/_libs/lib.pyx:993:23: E261 at least two spaces before inline comment
pandas/_libs/lib.pyx:1050:7: E271 multiple spaces after keyword
pandas/_libs/lib.pyx:1054:1: E265 block comment should start with '# '
pandas/_libs/lib.pyx:1139:11: E261 at least two spaces before inline comment
pandas/_libs/lib.pyx:1288:20: E261 at least two spaces before inline comment
pandas/_libs/lib.pyx:1290:22: E261 at least two spaces before inline comment
pandas/_libs/lib.pyx:1796:17: E129 visually indented line with same indent as next logical line
pandas/_libs/tslib.pyx:422:36: E241 multiple spaces after ','
pandas/_libs/tslib.pyx:621:28: E222 multiple spaces after operator
pandas/_libs/tslib.pyx:765:17: W503 line break before binary operator
pandas/_libs/tslib.pyx:766:17: W503 line break before binary operator
pandas/_libs/tslib.pyx:984:66: W291 trailing whitespace
pandas/_libs/tslib.pyx:1024:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/tslib.pyx:1265:34: E127 continuation line over-indented for visual indent
pandas/_libs/tslib.pyx:1353:17: W503 line break before binary operator
pandas/_libs/tslib.pyx:1438:5: E129 visually indented line with same indent as next logical line
pandas/_libs/tslib.pyx:1524:19: E271 multiple spaces after keyword
pandas/_libs/tslib.pyx:1675:5: E129 visually indented line with same indent as next logical line
pandas/_libs/tslib.pyx:2024:5: E129 visually indented line with same indent as next logical line
pandas/_libs/tslib.pyx:2024:17: W503 line break before binary operator
pandas/_libs/tslib.pyx:2292:11: E271 multiple spaces after keyword
pandas/_libs/tslib.pyx:2371:26: E261 at least two spaces before inline comment
pandas/_libs/tslib.pyx:2466:18: W503 line break before binary operator
pandas/_libs/tslib.pyx:2545:29: E127 continuation line over-indented for visual indent
pandas/_libs/tslib.pyx:2731:5: E301 expected 1 blank line, found 0
pandas/_libs/tslib.pyx:2886:21: W503 line break before binary operator
pandas/_libs/tslib.pyx:3017:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/src/reduce.pyx:1:1: E265 block comment should start with '# '
pandas/_libs/src/reduce.pyx:515:31: E261 at least two spaces before inline comment
pandas/_libs/src/reduce.pyx:535:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/src/inference.pyx:170:17: W503 line break before binary operator
pandas/_libs/src/inference.pyx:452:13: E129 visually indented line with same indent as next logical line
pandas/_libs/tslibs/fields.pyx:43:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/fields.pyx:44:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/fields.pyx:45:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/fields.pyx:46:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/fields.pyx:47:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/fields.pyx:48:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/fields.pyx:49:29: E261 at least two spaces before inline comment
pandas/_libs/tslibs/frequencies.pyx:166:5: E123 closing bracket does not match indentation of opening bracket's line
pandas/_libs/tslibs/parsing.pyx:51:1: E305 expected 2 blank lines after class or function definition, found 1
pandas/_libs/tslibs/parsing.pyx:202:44: E127 continuation line over-indented for visual indent
pandas/_libs/tslibs/parsing.pyx:233:38: W503 line break before binary operator
pandas/_libs/tslibs/parsing.pyx:237:40: W503 line break before binary operator
pandas/_libs/tslibs/parsing.pyx:245:38: W503 line break before binary operator
pandas/_libs/tslibs/parsing.pyx:252:38: W503 line break before binary operator
pandas/_libs/tslibs/parsing.pyx:320:31: E261 at least two spaces before inline comment
pandas/_libs/tslibs/parsing.pyx:393:1: E265 block comment should start with '# '
pandas/_libs/tslibs/parsing.pyx:407:28: E261 at least two spaces before inline comment
pandas/_libs/tslibs/parsing.pyx:452:28: E261 at least two spaces before inline comment
pandas/_libs/tslibs/parsing.pyx:509:9: E129 visually indented line with same indent as next logical line
pandas/_libs/tslibs/parsing.pyx:528:1: E265 block comment should start with '# '
pandas/_libs/tslibs/timedeltas.pyx:226:5: E129 visually indented line with same indent as next logical line
pandas/_libs/tslibs/timedeltas.pyx:226:13: W503 line break before binary operator
pandas/_libs/tslibs/timezones.pyx:159:1: E265 block comment should start with '# '
pandas/_libs/tslibs/timezones.pyx:177:5: E129 visually indented line with same indent as next logical line
pandas/_libs/tslibs/timezones.pyx:177:13: W503 line break before binary operator
pandas/_libs/tslibs/timezones.pyx:249:50: E261 at least two spaces before inline comment
pandas/_libs/tslibs/conversion.pyx:210:30: W503 line break before binary operator
pandas/_libs/tslibs/conversion.pyx:250:30: E127 continuation line over-indented for visual indent
pandas/_libs/tslibs/conversion.pyx:250:30: W503 line break before binary operator
pandas/_libs/tslibs/conversion.pyx:417:47: E261 at least two spaces before inline comment
pandas/_libs/tslibs/strptime.pyx:112:37: E127 continuation line over-indented for visual indent
pandas/_libs/tslibs/strptime.pyx:173:35: E127 continuation line over-indented for visual indent
pandas/_libs/tslibs/strptime.pyx:208:17: E265 block comment should start with '# '
pandas/_libs/tslibs/strptime.pyx:209:17: E265 block comment should start with '# '
pandas/_libs/tslibs/strptime.pyx:308:18: E261 at least two spaces before inline comment
pandas/_libs/tslibs/strptime.pyx:473:49: E127 continuation line over-indented for visual indent
pandas/_libs/tslibs/strptime.pyx:546:13: E265 block comment should start with '# '
pandas/_libs/tslibs/strptime.pyx:614:20: E261 at least two spaces before inline comment
pandas/_libs/tslibs/strptime.pyx:625:27: E241 multiple spaces after ','
pandas/io/msgpack/_packer.pyx:2:1: E265 block comment should start with '# '
pandas/io/msgpack/_unpacker.pyx:2:1: E265 block comment should start with '# '
pandas/io/msgpack/_unpacker.pyx:23:28: E261 at least two spaces before inline comment
pandas/io/msgpack/_unpacker.pyx:103:47: E261 at least two spaces before inline comment
pandas/io/msgpack/_unpacker.pyx:260:52: E261 at least two spaces before inline comment
pandas/io/msgpack/_unpacker.pyx:470:5: E265 block comment should start with '# '
pandas/io/msgpack/_unpacker.pyx:473:5: E265 block comment should start with '# '

I'm happy to clean these up, but doubt you want a giant sprawling PR.

@jbrockmendel
Copy link
Member Author

Reverted the lint.sh changes in the hopes of actually closing this out; opening a separate PR with the lint changes shortly.

@codecov
Copy link

codecov bot commented Oct 31, 2017

Codecov Report

Merging #18043 into master will increase coverage by <.01%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #18043      +/-   ##
==========================================
+ Coverage   91.24%   91.25%   +<.01%     
==========================================
  Files         163      163              
  Lines       50114    50114              
==========================================
+ Hits        45729    45732       +3     
+ Misses       4385     4382       -3
Flag Coverage Δ
#multiple 89.06% <ø> (+0.02%) ⬆️
#single 40.24% <ø> (-0.06%) ⬇️
Impacted Files Coverage Δ
pandas/io/gbq.py 25% <0%> (-58.34%) ⬇️
pandas/core/frame.py 97.75% <0%> (-0.1%) ⬇️
pandas/plotting/_converter.py 65.2% <0%> (+1.81%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c65a0f5...4b09c96. Read the comment docs.

@codecov
Copy link

codecov bot commented Oct 31, 2017

Codecov Report

Merging #18043 into master will increase coverage by <.01%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #18043      +/-   ##
==========================================
+ Coverage   91.24%   91.25%   +<.01%     
==========================================
  Files         163      163              
  Lines       50114    50114              
==========================================
+ Hits        45729    45732       +3     
+ Misses       4385     4382       -3
Flag Coverage Δ
#multiple 89.06% <ø> (+0.02%) ⬆️
#single 40.24% <ø> (-0.06%) ⬇️
Impacted Files Coverage Δ
pandas/io/gbq.py 25% <0%> (-58.34%) ⬇️
pandas/core/frame.py 97.75% <0%> (-0.1%) ⬇️
pandas/plotting/_converter.py 65.2% <0%> (+1.81%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c65a0f5...4b09c96. Read the comment docs.

@jreback jreback merged commit 08158c0 into pandas-dev:master Oct 31, 2017
@jreback
Copy link
Contributor

jreback commented Oct 31, 2017

this is fine, you can lint in the other PR.

@jreback jreback added this to the 0.22.0 milestone Oct 31, 2017
GuessWhoSamFoo pushed a commit to GuessWhoSamFoo/pandas that referenced this pull request Nov 1, 2017
No-Stream pushed a commit to No-Stream/pandas that referenced this pull request Nov 28, 2017
@jbrockmendel jbrockmendel deleted the tslibs-conversion6 branch December 8, 2017 19:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code Style Code style, linting, code_checks Datetime Datetime data dtype
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants