-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
.replace() raises when replacing strings #21078
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
Comments
Hmm I'm not able to reproduce on Python 3.6. Can you past the full traceback? |
I don't understand the bit about "type aliases". Are you overriding a builting with something from the |
@TomAugspurger I added the full traceback |
Does this raise for you?
If so, can you check the Python issue tracker to see if this has been filed? |
That works fine on 3.5.4 for me. Python 3.5.4 | packaged by conda-forge | (default, Aug 10 2017, 01:41:15)
[GCC 4.2.1 Compatible Apple LLVM 6.1.0 (clang-602.0.53)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import re
>>> import typing
>>> isinstance(re.compile(''), typing.re.Pattern)
True
>>> Can you try upgrading from 3.5.1 to a later point release? |
It definitely works with 3.5.4 but doesn't work with 3.5.2 either |
OK. See #20553 for reference. If you want, you can make a PR using the old way for Python 3.5.2 (or 3) and older... Or upgrade to the latest point release |
Will do, thanks! |
I had the same issue using the same Python 3.5.2. I just opened up the PR for it to revert it back. |
Code Sample, a copy-pastable example if possible
Problem description
This raises the following error:
This behavior is exclusive to the new version 0.23. Previous versions work as expected.
Full traceback
Expected Output
Output of
pd.show_versions()
INSTALLED VERSIONS
commit: None
python: 3.5.1.final.0
python-bits: 64
OS: Linux
OS-release: 4.13.13-5-pve
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: en_US.UTF-8
LANG: en_US.UTF-8
LOCALE: en_US.UTF-8
pandas: 0.23.0
pytest: None
pip: 8.1.1
setuptools: 20.7.0
Cython: None
numpy: 1.14.3
scipy: 1.1.0
pyarrow: None
xarray: None
IPython: 6.4.0
sphinx: None
patsy: None
dateutil: 2.6.1
pytz: 2018.4
blosc: None
bottleneck: None
tables: None
numexpr: None
feather: None
matplotlib: 2.2.2
openpyxl: None
xlrd: None
xlwt: None
xlsxwriter: None
lxml: None
bs4: None
html5lib: 0.999
sqlalchemy: None
pymysql: None
psycopg2: None
jinja2: 2.10
s3fs: None
fastparquet: None
pandas_gbq: None
pandas_datareader: None
The text was updated successfully, but these errors were encountered: