Skip to content
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

PyArray_Diagonal view transition for 1.9 (Trac #2136) #596

Closed
numpy-gitbot opened this issue Oct 19, 2012 · 4 comments · Fixed by #3645
Closed

PyArray_Diagonal view transition for 1.9 (Trac #2136) #596

numpy-gitbot opened this issue Oct 19, 2012 · 4 comments · Fixed by #3645

Comments

@numpy-gitbot
Copy link

Original ticket http://projects.scipy.org/numpy/ticket/2136 on 2012-05-19 by @njsmith, assigned to unknown.

Originally this was scheduled to happen in 1.8, but 1.7 was released 2013-02-10, and then we're accelerating the release schedule so that 1.8 will be only a few months later -- which seems too soon to actually take the next step in this deprecation plan.

Current plan: make the changes below in whichever release comes on or after: ?? (to be determined on mailing list)

Starting in 1.<?>, PyArray_Diagonal is supposed to start returning a non-writeable view.

To do:

  • Make the (trivial) change at the bottom of PyArray_Diagonal
  • Update the numpy.diagonal documentation
  • Make a note in the release notes
  • Optionally, remove NPY_ARRAY_WARN_ON_WRITE flag. If so, see the
    below pull request to find the code to change. Even if we decide
    to keep it around for a rainy day, the message in
    array_might_be_written should have the references to diagonals
    removed.
  • File a new ticket to make the returned array writeable, at some future date.

Reference: #280

@numpy-gitbot
Copy link
Author

@rgommers wrote on 2012-05-19

@numpy-gitbot
Copy link
Author

@rgommers wrote on 2012-05-19

Note, don't close this ticket once the change for 1.8 is made - there's a change to be made for 1.9 as well. See PR-280 for details.

@numpy-gitbot
Copy link
Author

@njsmith wrote on 2012-05-19

Shoot, I meant to put "File a new ticket for the 1.9 milestone" as the last item on the todo list and then forgot. Thanks for catching that :-)

@charris
Copy link
Member

charris commented Aug 12, 2013

I went ahead and put in a PR for the views. I expect the 1.8 release will come out in Oct if we are lucky. Eight months is probably enough and developers have probably been tracking 1.8.0-devel for more than a year.

charris added a commit to charris/numpy that referenced this issue Aug 22, 2013
Also remove the test_diagonal_deprecation test and add test that
checks that a view is returned and that it is not writeable.

Closes numpy#596.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants