BrandonFors/pandas-github-issues huggingface dataset:
CLN: fix some issues in asv benchmark suite
State: closed

Was trying to run benchmarks, and bumped into some issue (+ the DataMatrix, I just removed that as this is now removed from pandas, so not much sense having benchmarks for that)


Labels:
name: Performance
description: Memory or execution speed performance
name: Clean

Comments:
@pv added another commit for tables/pytables as well

## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13630?src=pr) is **84.33%**

> Merging [#13630](https://codecov.io/gh/pydata/pandas/pull/13630?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will decrease coverage by **<.01%**

``` diff
@@             master     #13630   diff @@
==========================================
  Files           138        138          
  Lines         51096      51095     -1   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43094      43093     -1   
  Misses         8002       8002          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [dbd5330...6b6f07f](https://codecov.io/gh/pydata/pandas/compare/dbd53306e4a1c091cf41426d1297648b042c771c...6b6f07fdba4e0abe66c84fc2ea49124d20eb65c1?src=pr)
CLN: Removed outtype in DataFrame.to_dict
State: closed

Follows up from #8486 in `0.15.0` by removing `outtype` in `DataFrame.to_dict()`

Fortunately or unfortunately, no tests were written then to test the deprecation, so there was nothing to remove from the test suite this time around.


Labels:
name: Deprecate
description: Functionality to remove in pandas

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13627?src=pr) is **84.33%**

> Merging [#13627](https://codecov.io/gh/pydata/pandas/pull/13627?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will decrease coverage by **<.01%**

``` diff
@@             master     #13627   diff @@
==========================================
  Files           138        138          
  Lines         51100      51099     -1   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43097      43096     -1   
  Misses         8003       8003          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [65849d3...1b5099d](https://codecov.io/gh/pydata/pandas/compare/65849d3c9feea395d6e6a124f7a3b11ecdb943cb...1b5099d4ef940664e4b8f6591384162395969d60?src=pr)

@jreback : Made the requested doc change (no tests need as a result hence the `[ci skip]`, so ready to merge if there are no other concerns.

@gfyoung Thanks!
BUG: Handle infinite values correctly in Series.argmax
State: closed

- [ X] closes #13595
- [X ] tests added / passed
- [X ] passes `git diff upstream/master | flake8 --diff`
- [X ] whatsnew entry


Labels:
name: Bug
name: Numeric Operations
description: Arithmetic, Comparison, and Logical operations

Comments:
@matthewwillian You have some PEP8 issues (see the travis log at the bottom: https://travis-ci.org/pydata/pandas/jobs/144182270), and a failing test.

Okay, thank you. I will take a look.

@matthewwillian Can you update/rebase?

It's great if you can include the fix for `argmin` for `-inf`.

```
pd.Series([1, 3, -np.inf]).argmin()
0
```

can you rebase

can you rebase / update?

can you rebase and move release notes to 0.19.2

can you rebase / update
closing, but if you want to update, pls comment.
BUG: Invalid Timedelta op may raise ValueError
State: closed

- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`
- [x] whatsnew entry

`Timedelta` op may raise `ValueError` for invalid inputs because of internal conversion. 

```
pd.Timedelta('1 days') + 'a'
# ValueError: unit abbreviation w/o a number
```

Now it raises `TypeError`.


Labels:
name: Bug
name: Error Reporting
description: Incorrect or improved errors from pandas
name: Timedelta
description: Timedelta data type

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13624?src=pr) is **84.33%**

> Merging [#13624](https://codecov.io/gh/pydata/pandas/pull/13624?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will increase coverage by **<.01%**

``` diff
@@             master     #13624   diff @@
==========================================
  Files           138        138          
  Lines         51100      51104     +4   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
+ Hits          43097      43101     +4   
  Misses         8003       8003          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [65849d3...856df95](https://codecov.io/gh/pydata/pandas/compare/65849d3c9feea395d6e6a124f7a3b11ecdb943cb...856df9517322d6547a3a9e664daac5cdb89554d1?src=pr)
ENH: DataFrame sort columns by rows: sort_values(axis=1)
State: closed

- [X] closes #10806
- [X] tests added / passed
- [X] passes `git diff upstream/master | flake8 --diff`
- [X] whatsnew entry


Labels:
name: Enhancement
name: Reshaping
description: Concat, Merge/Join, Stack/Unstack, Explode

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13622?src=pr) is **84.38%**

> Merging [#13622](https://codecov.io/gh/pydata/pandas/pull/13622?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will increase coverage by **0.04%**

``` diff
@@             master     #13622   diff @@
==========================================
  Files           138        142     +4   
  Lines         51100      51222   +122   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
+ Hits          43097      43223   +126   
+ Misses         8003       7999     -4   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [65849d3...ea2d89e](https://codecov.io/gh/pydata/pandas/compare/65849d3c9feea395d6e6a124f7a3b11ecdb943cb...ea2d89eb82a915d522d783c35e1759b826821713?src=pr)

Looks good. @jreback OK for you?

ok minor comments, ps rebase and ping on green.

@IamJeffG fixed the remaining comments when merging (we already asked you to update the whatsnew sentence enough :-)) 
Thanks a lot for the enhancement!

Thanks for taking care of it @jorisvandenbossche !

(and now your geopandas PR .. :-) I try to take a look this evening!)
TST: reorganize tools.tests
State: closed

- [x] tests passed
- [x] passes `git diff upstream/master | flake8 --diff`

`merge`, `join` and `concat` related tests are mixed each other. Cleaned up these tests.


Labels:
name: Testing
description: pandas testing functions or related to the test suite
name: Clean

Comments:
Looks good!

## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13619?src=pr) is **84.38%**

> Merging [#13619](https://codecov.io/gh/pydata/pandas/pull/13619?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will not change coverage

``` diff
@@             master     #13619   diff @@
==========================================
  Files           142        142          
  Lines         51225      51225          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
  Hits          43225      43225          
  Misses         8000       8000          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [20de266...0745416](https://codecov.io/gh/pydata/pandas/compare/20de2661c8eff66e465248cbe28062eae0e0e3bb...0745416354a3c5409c8ea9dc31ad8b981fc3995a?src=pr)

lgtm, prob will require rebase after #13147 

Thanks @sinhrks !
DOC: asfreq clarify original NaNs are not filled (GH9963)
State: closed

Closes #9963


Labels:
name: Docs

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13617?src=pr) is **84.33%**

> Merging [#13617](https://codecov.io/gh/pydata/pandas/pull/13617?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will not change coverage

``` diff
@@             master     #13617   diff @@
==========================================
  Files           138        138          
  Lines         51100      51100          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
  Hits          43097      43097          
  Misses         8003       8003          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [5605f99...0f8931f](https://codecov.io/gh/pydata/pandas/compare/5605f99105b6a97fb950fbebbf83d2cac0b23ef1...0f8931f20d6a507a9e0b2bfaef0b3ddce953b3cc?src=pr)

lgtm
CLN: remove deprecated io.sql uquery and tquery functions
State: closed

Were already deprecated since 0.14


Labels:
name: IO SQL
description: to_sql, read_sql, read_sql_query
name: Deprecate
description: Functionality to remove in pandas
name: Clean

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13616?src=pr) is **84.55%**

> Merging [#13616](https://codecov.io/gh/pydata/pandas/pull/13616?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will increase coverage by **0.01%**

``` diff
@@             master     #13616   diff @@
==========================================
  Files           141        141          
  Lines         51209      51172    -37   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43294      43269    -25   
+ Misses         7915       7903    -12   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [57b373c...197f663](https://codecov.io/gh/pydata/pandas/compare/57b373c97a8cd72f29a6206c5859661d8b926a97...197f663e835224e46ba2abb9d28df10a06a2d55c?src=pr)
ENH: Allow to_sql to recognize single sql type (GH11886)
State: closed

Rebase of PR https://github.com/pydata/pandas/pull/13252

Closes https://github.com/pydata/pandas/issues/11886


Labels:
name: Enhancement
name: IO SQL
description: to_sql, read_sql, read_sql_query

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13614?src=pr) is 84.38% (diff: 100%)

> No coverage report found for **master** at 1cd1026.
> 
> Powered by [Codecov](https://codecov.io?src=pr). Last update [1cd1026...554f7e8](https://codecov.io/gh/pydata/pandas/compare/1cd1026ed7061882a05521a7c16200eadae591e4...554f7e80fd2b0a0901597c43eac0ba92a529c4c5?src=pr)

Rebased this, @jreback or @sinhrks can you do a quick sanity check?

lgtm.
CLN: Removed levels attribute from Categorical
State: closed

Deprecated back in `0.15.0` and therefore long overdue.  Closes #8376.


Labels:
name: Categorical
description: Categorical Data Type
name: Deprecate
description: Functionality to remove in pandas

Comments:
Looks good to me

cc @janschulz 

## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13612?src=pr) is **84.38%**

> Merging [#13612](https://codecov.io/gh/pydata/pandas/pull/13612?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will increase coverage by **<.01%**

``` diff
@@             master     #13612   diff @@
==========================================
  Files           142        142          
  Lines         51235      51223    -12   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43235      43226     -9   
+ Misses         8000       7997     -3   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [c9a27ed...f1254df](https://codecov.io/gh/pydata/pandas/compare/c9a27ede0925ddbaa8d3ec9efd3c332a636505cf...f1254dfc03bee29120f844af2f0ff515fbe8ae82?src=pr)

@jreback , @janschulz : relocated those pickle tests for `Categorical`, and Travis is still happy.  Ready to merge if there are no other concerns.

thanks!
TST: add tests for Timestamp.toordinal/fromordinal
State: closed

- [x] follow-up for #13593
- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`

added tests and fixed missed doc change.


Labels:
name: Testing
description: pandas testing functions or related to the test suite

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13610?src=pr) is **84.38%**

> Merging [#13610](https://codecov.io/gh/pydata/pandas/pull/13610?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will not change coverage

``` diff
@@             master     #13610   diff @@
==========================================
  Files           142        142          
  Lines         51225      51225          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
  Hits          43225      43225          
  Misses         8000       8000          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [20de266...28f8d41](https://codecov.io/gh/pydata/pandas/compare/20de2661c8eff66e465248cbe28062eae0e0e3bb...28f8d411aac7cf091ce968b5693825f9f82d896c?src=pr)

thanks!
API: Change Period('NAT') to return NaT
State: closed

- [x] closes #12759, #13582
- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`
- [x] whatsnew entry
- `pd.Period('NaT', freq='D')` now returns `pd.NaT` rather than its own nat repr. 
- To be compat with `Period` arithmetic, `pd.NaT` now supports addition / subtraction with `int` (previously `ValueError`).

```
pd.NaT + 1
# pd.NaT
```

Added tests for following:
- [x] `Period` and `PeriodIndex`, `Series` ops
  - [x] add, sub, comp
- [x] `PeriodIndex` creation from list-like which contains `Period` and `NaT` (#13430)
- [x] `PeriodIndex` boxing
- [x] `.to_period`
- [x]  `__contains__` any NaT-like(`pd.NaT, None, float('nan'), np.nan`) 


Labels:
name: Missing-data
description: np.nan, pd.NaT, pd.NA, dropna, isnull, interpolate
name: Period
description: Period data type

Comments:
CC @MaximilianR

## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13609?src=pr) is **84.38%**

> Merging [#13609](https://codecov.io/gh/pydata/pandas/pull/13609?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will decrease coverage by **<.01%**

``` diff
@@             master     #13609   diff @@
==========================================
  Files           142        142          
  Lines         51225      51225          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43225      43224     -1   
- Misses         8000       8001     +1   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [20de266...9305c36](https://codecov.io/gh/pydata/pandas/compare/20de2661c8eff66e465248cbe28062eae0e0e3bb...9305c36ca536aa7877517c1cdfb9df9481a01194?src=pr)

@sinhrks Can you rebase this? Then it will be easier to review the additional changes (as I think the first commit is now already in master?)

@jorisvandenbossche sure. rebased.

thanks @sinhrks this is really nice!
CLN: Fix compile time warnings
State: closed

- [x] passes `git diff upstream/master | flake8 --diff`

This commit suppresses these warnings

warning: comparison of constant -1 with expression\
of type 'PANDAS_DATETIMEUNIT' is always true\
[-Wtautological-constant-out-of-range-compare]


Labels:
name: Clean

Comments:
can u run all tests on Windows and report (if u can) otherwise I will

Sorry I can not setup Windows environments soonly 😢 

## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13607?src=pr) is **84.33%**

> Merging [#13607](https://codecov.io/gh/pydata/pandas/pull/13607?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will not change coverage

``` diff
@@             master     #13607   diff @@
==========================================
  Files           138        138          
  Lines         51100      51100          
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
  Hits          43097      43097          
  Misses         8003       8003          
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [2f7fdd0...e9eee1d](https://codecov.io/gh/pydata/pandas/compare/2f7fdd07eb0925016a28cf9ff324e351eac0c4df...e9eee1d4b31358d4b32dd5cb9b8ab40d1657d9e1?src=pr)

ok @yui-knk this lgtm. and tests out on windows. (the warning only seems to appear on linux/osx), but that's ok!

pls add a whatsnew entry in bug fix for 0.19.0, reference this PR. ping when green.

@jreback I added a whatsnew entry :)

thanks @yui-knk 

No problem 😄
CLN: remove radd workaround in ops.py
State: closed

- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`

Remove workaround added in #353. The test added at that time has been passed.
- https://github.com/pydata/pandas/blob/master/pandas/tests/series/test_operators.py#L1264


Labels:
name: Numeric Operations
description: Arithmetic, Comparison, and Logical operations
name: Clean

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13606?src=pr) is **84.31%**

> Merging [#13606](https://codecov.io/gh/pydata/pandas/pull/13606?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will increase coverage by **<.01%**

``` diff
@@             master     #13606   diff @@
==========================================
  Files           138        138          
  Lines         51157      51146    -11   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43131      43122     -9   
+ Misses         8026       8024     -2   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [5701c69...d873aad](https://codecov.io/gh/pydata/pandas/compare/5701c69369264f3aa6f571384602ceec1133dabc...d873aade88fec9e00875cfe9f5d65e87266eb0a1?src=pr)

lgtm
independent of #13605 ?

Yes independent, and whichever order is OK.
CLN: Cleanup ops.py
State: closed

- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`

Cleanup duplicated code paths before fixing some ops related issues.


Labels:
name: Numeric Operations
description: Arithmetic, Comparison, and Logical operations
name: Clean

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13605?src=pr) is **84.33%**

> Merging [#13605](https://codecov.io/gh/pydata/pandas/pull/13605?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will decrease coverage by **<.01%**

``` diff
@@             master     #13605   diff @@
==========================================
  Files           138        138          
  Lines         51100      51092     -8   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43097      43090     -7   
+ Misses         8003       8002     -1   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [5605f99...729997b](https://codecov.io/gh/pydata/pandas/compare/5605f99105b6a97fb950fbebbf83d2cac0b23ef1...729997b93ded983ccbdcbb1d7c57d00c0c89fe21?src=pr)

Looks good! Small comment

thxs!
CLN: Initialization coincides with mapping, hence with uniqueness check
State: closed

- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`

Rebased version of https://github.com/pydata/pandas/pull/10229 which was [actually not](https://github.com/pydata/pandas/pull/10229#issuecomment-131470116) fixed by https://github.com/pydata/pandas/pull/10199.

Nothing particular relevant, just wanted to delete this branch locally and noticed it still applies: you'll judge what to do of it.


Labels:
name: Indexing
description: Related to indexing on series/frames, not to indexes themselves
name: Clean

Comments:
can you make a tests which fails w/o this and passes with.

I don't think, but feel free to suggest.

thanks @toobaz this looks fine.
DEPR: rename Timestamp.offset to .freq
State: closed

- [x] closes #12160
- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`
- [x] whatsnew entry


Labels:
name: Deprecate
description: Functionality to remove in pandas

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13593?src=pr) is **84.31%**

> No coverage report found for **master** at 1edc1df.
> 
> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [1edc1df...c7749d5](https://codecov.io/gh/pydata/pandas/compare/1edc1df161f3274218fcd19c23663ea63386f105...c7749d52d61a4de90e3910b8ae431d62092f3847?src=pr)

thanks @sinhrks 

I had to do a couple of more renames to avoid the warnings...but no biggie.

not that `Timestamp.from_ordinal` also needed changing, but I don't think its tested much.

Thanks, let me do a follow-up for testing `fromordinal`.
BUG: Series/Index contains NaT with object dtype comparison incorrect
State: closed

- [x] closes #9005 
- [x] tests added / passed
- [x] passes `git diff upstream/master | flake8 --diff`
- [x] whatsnew entry

`Series` and `Index` compares `NaT == NaT` as `True` if it has `object` dtype. 

```
pd.Series([pd.NaT])
#0   NaT
# dtype: datetime64[ns]

# OK
pd.Series([pd.NaT]) == pd.NaT
#0    False
# dtype: bool

# NG in object dtype
pd.Series([pd.NaT], dtype=object) == pd.NaT
#0    True
# dtype: bool

# OK
pd.Index([pd.NaT]) == pd.NaT
array([False], dtype=bool)

# NG in object dtype
pd.Index([pd.NaT], dtype=object) == pd.NaT
# array([ True], dtype=bool)
```


Labels:
name: Bug
name: Missing-data
description: np.nan, pd.NaT, pd.NA, dropna, isnull, interpolate

Comments:
## [Current coverage](https://codecov.io/gh/pydata/pandas/pull/13592?src=pr) is **84.33%**

> Merging [#13592](https://codecov.io/gh/pydata/pandas/pull/13592?src=pr) into [master](https://codecov.io/gh/pydata/pandas/branch/master?src=pr) will increase coverage by **0.01%**

``` diff
@@             master     #13592   diff @@
==========================================
  Files           138        138          
  Lines         51165      51100    -65   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
- Hits          43142      43097    -45   
+ Misses         8023       8003    -20   
  Partials          0          0          
```

> Powered by [Codecov](https://codecov.io?src=pr). Last updated by [1edc1df...f95dae7](https://codecov.io/gh/pydata/pandas/compare/1edc1df161f3274218fcd19c23663ea63386f105...f95dae7ad6648a68ee0f63450854f676e14badf4?src=pr)

lgtm. Do we have an associated issue? I do recall this somewhere.

Maybe #9005, though it looks to be fixed on current master (but added tests for native/object dtypes).

Ah, found #9005 is not fixed yet. If `NaT` is on rhs (on current master):

```
pd.Series([pd.Timestamp('2011-01-01')]) > pd.Series([pd.NaT])
# 0    True
# dtype: bool
```

Already included the fix to this PR.

thanks!