Skip to content

Inconsistent error raising in indexing #14525

Closed
@cyrusmaher

Description

@cyrusmaher

A small, complete example of the issue

x = np.random.randn(2, 2)
y = pd.Series(range(2))
y.loc[range(2)] = x # succeeds
y.loc[:] = x # fails

Expected Output

Since we're assigning a 2D array to a 1D vector that is smaller than the raveled array, I would expect both assignments to fail.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions