Skip to content

Commit

Permalink
Remove future statements (#3194)
Browse files Browse the repository at this point in the history
* remove future statements

* add commented out pyupgrade

* add py3-only & keep-percent to pyupgrade config

* add isort to commented out hooks

* add a couple of items to isort config
  • Loading branch information
max-sixty authored Aug 9, 2019
1 parent 5b36e80 commit 58001d7
Show file tree
Hide file tree
Showing 13 changed files with 19 additions and 22 deletions.
13 changes: 13 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,16 @@ repos:
rev: v2.2.3
hooks:
- id: flake8
# run these occasionally, ref discussion https://github.com/pydata/xarray/pull/3194
# - repo: https://github.com/asottile/pyupgrade
# rev: v1.22.1
# hooks:
# - id: pyupgrade
# args:
# - "--py3-only"
# # remove on f-strings in Py3.7
# - "--keep-percent-format"
# - repo: https://github.com/timothycrosley/isort
# rev: 4.3.21-2
# hooks:
# - id: isort
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import itertools

import numpy as np
Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/dataarray_missing.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import pandas as pd

import xarray as xr
Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/dataset_io.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import os

import numpy as np
Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/indexing.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import numpy as np
import pandas as pd

Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/interp.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import numpy as np
import pandas as pd

Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/reindexing.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import numpy as np

import xarray as xr
Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/rolling.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import numpy as np
import pandas as pd

Expand Down
2 changes: 0 additions & 2 deletions asv_bench/benchmarks/unstacking.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from __future__ import absolute_import, division, print_function

import numpy as np

import xarray as xr
Expand Down
8 changes: 4 additions & 4 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#
# All configuration values have a default; values that are commented out
# serve to show the default.
from __future__ import absolute_import, division, print_function


import datetime
import os
Expand Down Expand Up @@ -262,11 +262,11 @@

latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',
# 'papersize': 'letterpaper',
# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',
# 'pointsize': '10pt',
# Additional stuff for the LaTeX preamble.
#'preamble': '',
# 'preamble': '',
}

# Grouping the document tree into LaTeX files. List of tuples
Expand Down
1 change: 0 additions & 1 deletion doc/gallery/plot_cartopy_facetgrid.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
.. _this discussion: https://github.com/pydata/xarray/issues/1397#issuecomment-299190567
""" # noqa

from __future__ import division

import cartopy.crs as ccrs
import matplotlib.pyplot as plt
Expand Down
2 changes: 2 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ exclude=
doc

[isort]
default_section=THIRDPARTY
known_first_party=xarray
multi_line_output=3
include_trailing_comma=True
force_grid_wrap=0
Expand Down
1 change: 0 additions & 1 deletion versioneer.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,6 @@
"""

from __future__ import print_function

import errno
import json
Expand Down

0 comments on commit 58001d7

Please sign in to comment.