Skip to content

Commit

Permalink
Fixed all flakes
Browse files Browse the repository at this point in the history
  • Loading branch information
jlstevens committed Mar 8, 2016
1 parent 05a45cc commit c1b5818
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 12 deletions.
6 changes: 3 additions & 3 deletions holocube/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
from .element import (GeoElement, Cube, GeoImage, GeoContour, GeoPoints,
GeoFeature, WMTS, GeoTiles)
from . import plotting
from .element import GeoElement, Cube, GeoImage, GeoContour # noqa (API import)
from .element import GeoPoints, GeoFeature, WMTS, GeoTiles # noqa (API import)
from . import plotting # noqa (API import)
6 changes: 3 additions & 3 deletions holocube/element/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
from .cube import Cube
from .geo import (GeoElement, GeoPoints, GeoFeature, WMTS, GeoTiles,
GeoImage, GeoContour)
from .cube import Cube # noqa (API import)
from .geo import GeoElement, GeoPoints, GeoFeature # noqa (API import)
from .geo import WMTS, GeoTiles, GeoImage, GeoContour # noqa (API import)
5 changes: 2 additions & 3 deletions holocube/element/cube.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class Cube(Element):
"""

group = param.String(default='Cube')

def __init__(self, data, **params):
if not isinstance(data, iris.cube.Cube):
raise TypeError('Cube data must be of Iris Cube type.')
Expand All @@ -57,8 +57,7 @@ def __init__(self, data, **params):
else:
coords = data.dim_coords
coords = sorted(coords, key=sort_coords)
params['kdims'] = [coord_to_dimension(coord)
for coord in coords]
params['kdims'] = [coord_to_dimension(crd) for crd in coords]
if 'vdims' not in params:
params['vdims'] = [Dimension(data.name(), unit=str(data.units))]
super(Cube, self).__init__(data, **params)
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env python

import sys, os
import os
try:
from setuptools import setup
except ImportError:
Expand Down
2 changes: 0 additions & 2 deletions tests/test_cube.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import unittest

import numpy as np
from holocube.element.cube import Cube, coord_to_dimension
from iris.tests.stock import lat_lon_cube
Expand Down

0 comments on commit c1b5818

Please sign in to comment.