CLN: Remove unicode u string prefix
State: closed

- [X] xref #25725
- [X] tests added / passed
- [X] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`

More Python 2 removal.  Could use a second pair of eyes to make sure the regex I used to make these fixes wasn't overzealous anywhere.


Labels:
name: Unicode
description: Unicode strings
name: Clean

Comments:
I think as-is this will fail CI only because the following xfailed test is now passing, and we're being strict with XPASS here:

https://github.com/pandas-dev/pandas/blob/dca809b0151adb744940a727f5d82ca43f4c3ea4/pandas/tests/io/formats/test_to_csv.py#L355-L368

The only change I made a was removing the `u` prefix on lines 362-3, so it looks like this was only failing on Python 3 due to the expected string containing the prefixes?  I was able to manually confirm that this appears to be working on Python 3 and failing on Python 2 in the 0.24.2 release, meaning the issue was Python 2 specific and we can remove the `xfail`?

cc @jreback : Does the above make sense to you, or am I misinterpreting the issue?  If so, does it make sense to also close the associated issue #10813?


# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=h1) Report
> Merging [#25864](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/dca809b0151adb744940a727f5d82ca43f4c3ea4?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `n/a`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/25864/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #25864   +/-   ##
=======================================
  Coverage   91.47%   91.47%           
=======================================
  Files         173      173           
  Lines       52868    52868           
=======================================
  Hits        48362    48362           
  Misses       4506     4506
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.04% <0%> (ø)` | :arrow_up: |
| #single | `41.82% <0%> (ø)` | :arrow_up: |


------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=footer). Last update [dca809b...d655d4f](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=h1) Report
> Merging [#25864](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/dca809b0151adb744940a727f5d82ca43f4c3ea4?src=pr&el=desc) will **increase** coverage by `<.01%`.
> The diff coverage is `91.62%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/25864/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #25864      +/-   ##
==========================================
+ Coverage   91.47%   91.47%   +<.01%     
==========================================
  Files         173      173              
  Lines       52868    52872       +4     
==========================================
+ Hits        48362    48366       +4     
  Misses       4506     4506
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.04% <87.43%> (ø)` | :arrow_up: |
| #single | `41.82% <37.69%> (-0.01%)` | :arrow_down: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/arrays/categorical.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL2NhdGVnb3JpY2FsLnB5) | `95.96% <ø> (ø)` | :arrow_up: |
| [pandas/core/indexing.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhpbmcucHk=) | `90.87% <ø> (ø)` | :arrow_up: |
| [pandas/core/arrays/base.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL2Jhc2UucHk=) | `98.27% <ø> (ø)` | :arrow_up: |
| [pandas/core/indexes/multi.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9tdWx0aS5weQ==) | `95.62% <ø> (ø)` | :arrow_up: |
| [pandas/core/dtypes/dtypes.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvZHR5cGVzL2R0eXBlcy5weQ==) | `96.1% <ø> (ø)` | :arrow_up: |
| [pandas/errors/\_\_init\_\_.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2Vycm9ycy9fX2luaXRfXy5weQ==) | `100% <ø> (ø)` | :arrow_up: |
| [pandas/core/reshape/pivot.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvcmVzaGFwZS9waXZvdC5weQ==) | `96.55% <100%> (ø)` | :arrow_up: |
| [pandas/io/formats/format.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2lvL2Zvcm1hdHMvZm9ybWF0LnB5) | `97.99% <100%> (ø)` | :arrow_up: |
| [pandas/core/arrays/period.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL3BlcmlvZC5weQ==) | `98.53% <100%> (ø)` | :arrow_up: |
| [pandas/core/indexes/period.py](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9wZXJpb2QucHk=) | `92.06% <100%> (ø)` | :arrow_up: |
| ... and [8 more](https://codecov.io/gh/pandas-dev/pandas/pull/25864/diff?src=pr&el=tree-more) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=footer). Last update [dca809b...0fdc0cb](https://codecov.io/gh/pandas-dev/pandas/pull/25864?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

that issue looks pretty confusing so not sure
you can make strict=False to get this PR passing
okay, marked it as `@pytest.mark.xfail(strict=False)`
thanks @jschendel