Comments (7)
Thanks @melissawm. But this is odd - I don't know what :okwarning:
would do to resolve the issue if you're not seeing a warning. I'd be hesitant to add such a line when we don't see the failing on the CI without understanding further.
from pandas.
The UserWarning for
pd.to_datetime(pd.Series(["Jul 31, 2009", "Jan 10, 2010", None]))
seems to be strange because no warning occurs when I directly run this code in ipython.
This suggests to me you are using two different pythons when you build docs vs when you run in ipython. When you build and install pandas, what python is used?
from pandas.
@rhshadrach
I directly run the commands python make.py
and ipython
in the same conda environment. I have checked that they use the same python.
$ which ipython
/home1/hhz/miniconda3/envs/pandas_main/bin/ipython
$ which python
/home1/hhz/miniconda3/envs/pandas_main/bin/python
$ cat /home1/hhz/miniconda3/envs/pandas_main/bin/ipython
#!/home1/hhz/miniconda3/envs/pandas_main/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from IPython import start_ipython
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(start_ipython())
from pandas.
Very odd. I would suggest to try recreating your environment, but from the commands above I believe you've already done that.
from pandas.
Hi all, I am getting the same issue. Adding :okwarning:
to this block
pandas/doc/source/user_guide/timeseries.rst
Lines 199 to 204 in ec3eddd
solves the issue for me. I'm happy to submit a PR if that's the acceptable solution. Cheers!
from pandas.
@melissawm - If you run this code on its own (outside building the docs), what's the warning you're seeing?
from pandas.
Here you go, no warnings:
(pandas-dev) ➜ ~ ipython
Python 3.10.14 | packaged by conda-forge | (main, Mar 20 2024, 12:45:18) [GCC 12.3.0]
Type 'copyright', 'credits' or 'license' for more information
IPython 8.22.2 -- An enhanced Interactive Python. Type '?' for help.
In [1]: import pandas as pd
+ /home/melissa/micromamba/envs/pandas-dev/bin/ninja
[1/1] Generating write_version_file with a custom command
In [2]: pd.to_datetime(pd.Series(["Jul 31, 2009", "Jan 10, 2010", None])
...: )
Out[2]:
0 2009-07-31
1 2010-01-10
2 NaT
dtype: datetime64[ns]
In [3]: pd.to_datetime(["2005/11/23", "2010/12/31"])
Out[3]: DatetimeIndex(['2005-11-23', '2010-12-31'], dtype='datetime64[ns]', freq=None)
In [4]: pd.__version__
Out[4]: '2.2.0.dev0+1627.g9cd5e5546c.dirty'
In [5]:
from pandas.
Related Issues (20)
- BUG: pandas.errors.EmptyDataError
- BUG: Forcing an int dtype on DataFrame construction raises an odd error HOT 2
- BUG: passing non-trivial expressions to function within eval raises an error HOT 2
- ADMIN: Upgrade to mailman 3
- ENH: Allow `pd.set_option` to control the uuid4 seed used in `pd.io.formats.style.Renderer`
- BUG: Passing an empty Index to pd.DataFrame.from_records() produces a ValueError
- BUG: Adding or multiplying a pandas nullable dtype Series with a pyarrow dtype Series raises TypeError HOT 3
- BUG: Regression of Index.join() when return_indexers=True
- BUG: Slicing operator has a regression on Python 3.12 for a dataframe with categorical MultiIndex HOT 4
- BUG: groupby.first() with None values fills None value with next row HOT 5
- BUG: ./ci/code_checks.sh fails in local dev environment HOT 1
- Default string dtype (PDEP-14): naming convention to distinguish the dtype variants HOT 27
- BUG: Renaming a dataframe columns with a series containing duplicated index corrupts the dataframe HOT 4
- BUG: pd.DataFrame.set_index() detects "label" input instead of "iterator" when keys argument is a list
- BUILD: 3rd party licenses are missing from pandas binary wheels distributed on pypi HOT 1
- BUG: `read_parquet` doesn't convert categories to `pd.CategoricalDtype` when `dtype_backend="pyarrow"`
- BUG: Unable to open Stata 118 or 119 files saved in big-endian format that contain strL data
- BUG: RangeIndex.searchsorted() when using a negative step HOT 3
- BUG: inconsistent behavior of pandas.api.types.pandas_dtype
- BUG: DataFrame.groupby returns invalid value when dropna=False HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pandas.