Skip to content
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

Cleanup cimports #18556

Merged
merged 3 commits into from
Dec 3, 2017
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pandas/_libs/src/inference.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ from decimal import Decimal
cimport util
cimport cython
from tslibs.nattype import NaT
from tslib cimport convert_to_tsobject
from tslibs.conversion cimport convert_to_tsobject
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to add conversion.pxd as a dep for lib.pyx (tslib.pyd should have been there)

from tslibs.timedeltas cimport convert_to_timedelta64
from tslibs.timezones cimport get_timezone
from datetime import datetime, timedelta
Expand Down
3 changes: 0 additions & 3 deletions pandas/_libs/tslib.pxd

This file was deleted.

10 changes: 4 additions & 6 deletions pandas/_libs/tslib.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
# distutils: define_macros=CYTHON_TRACE_NOGIL=0

cimport numpy as np
from numpy cimport int64_t, import_array, ndarray, float64_t
from numpy cimport int64_t, ndarray, float64_t
import numpy as np
np.import_array()


from cpython cimport PyTypeObject, PyFloat_Check
Expand Down Expand Up @@ -35,18 +36,15 @@ from tslibs.np_datetime cimport (check_dts_bounds,
dayofweek, is_leapyear)
from tslibs.np_datetime import OutOfBoundsDatetime

from .tslibs.parsing import parse_datetime_string
from tslibs.parsing import parse_datetime_string

cimport cython
from cython cimport Py_ssize_t

import warnings

import pytz
UTC = pytz.utc

# initialize numpy
import_array()


from tslibs.timedeltas cimport cast_from_unit
from tslibs.timedeltas import Timedelta
Expand Down