-
Notifications
You must be signed in to change notification settings - Fork 260
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
Sprint: Pytest conversion #864
Comments
I can work on this one of the day of the week Feb 1st-7th, preferably Mon-Wed. I believe I converted all tests from |
@effigies thank you for organizing this! Tuesdays and Thursdays work for me in general. The chat room idea is nice for quick checks, but the issue/PRs process might be useful to keep tracking. |
In general I'm quite available during the week!! |
So would Tuesday, February 4 work for all three of you? Is there anybody that it wouldn't work for? Also, does anybody have a Windows machine for debugging any issues there? |
Tuesday would work for me, part from two hours (10am-12am EST).
No windows machine here...
…On Sun, Jan 26, 2020 at 11:35 AM Chris Markiewicz ***@***.***> wrote:
So would Tuesday, February 4 work for all three of you? Is there anybody
that it wouldn't work for?
Also, does anybody have a Windows machine for debugging any issues there?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#864?email_source=notifications&email_token=AAPF3WJJU5ME34DY3RLVXHTQ7W3VZA5CNFSM4KLSCEIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJ5YAYQ#issuecomment-578519138>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAPF3WIRGOUMV5A4UCAIBDDQ7W3VZANCNFSM4KLSCEIA>
.
--
Or A. Duek, PhD
Postdoctoral Associate
Harpaz-Rotem Stress and PTSD Lab
Yale University School of Medicine, Dept of Psychiatry
https://medicine.yale.edu/lab/harpazrotem/
https://www.ptsdstresslab.org/
+1 (203) 305 7172
*Please consider the environment before printing this e-mail *
|
Works for me, apart from the same two hours (unrelated tho) I have a Windows at home, will setup the proper environment to test it. |
Works for me!! I am on Linux and avaliable considering GMT+2 ;) |
Okay. I'll be around 9am-5pm EST (UTC-5), except a couple of calls from 12:45pm-2pm EST. I'll see if I can push them around, but we should have plenty of synchronous time, even if I can't. How would we like to do live chatting? I've gone ahead and set up a Riot.im channel (#nibabel:matrix.org). If people prefer, the Brainhack Mattermost is another option. I'd rather not set up gitter... |
Riot.im seems nice! I am fine with it. |
FWIW we use riot and jitsi for DataLad. This I +1 on riot ;-) |
Hi all, I just want to draw your attention to #865, which shows the diff of the |
and I will prepare description of my "workflow" for changing the tests, so people can use it if they don't have better ideas. |
Hi all. I've updated the top post with some tasks. Some can likely be broken down further, but I figure I'll leave that to the person who starts working on a given one to decide to split up jobs. Everybody in this thread thus far should have write access to the repository, so you can edit the top post to let people know you're working on it, break down the tasks, or link to a PR addressing it. And as a reminder, we'll be chatting on https://matrix.to/#/!GMrAjYhYGQqbvuNvJX:matrix.org?via=matrix.org, and we can open a Jitsi chat if video call makes sense at any point. I expect to be responsive from about 9am-12pm EST (UTC-5) and 1:30pm-5pm EST. |
@effigies - sounds good! I will try to be at 9ish. I completely forgot that I had still some tests in Also - I'm pretty sure that more tests should be edited... |
These is my workflow for converting the tests:
|
Ok! Thank you. I am working on nibabel.streamlines.tests.test_array_sequence which seems easy to me for beginning! |
Now I will work on nibabel.streamlines.tests.test_tractogram! |
I will be out from 8am-10am (UTC-5) ! |
@effigies - how can I find you on riot? I was able to login to my account, but not sure what to do next. |
The room is #nibabel:matrix.org. I assumed the link would get people there. |
not really, but trying to find you... |
If anybody needs help setting up a test environment, let me know and I can put together some instructions. |
I'll be happy to get some help on that matter. thanks |
@orduek - hi, do you have conda installed on your laptop? |
Sure. I have miniconda
…On Tue, Feb 4, 2020, 12:51 PM Dorota Jarecka ***@***.***> wrote:
@orduek <https://github.com/orduek> - hi, do you have conda installed on
your laptop?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#864?email_source=notifications&email_token=AAPF3WOPLFCGAXIXPLS7QPDRBGTJHA5CNFSM4KLSCEIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEKYSAMA#issuecomment-582033456>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAPF3WKNKBDAYCQV7R75YYDRBGTJHANCNFSM4KLSCEIA>
.
|
let me know if this works and if you have any questions |
Thanks, @djarecka. Yeah, just to make very explicit, I use the following:
And then you can run Lines 136 to 196 in ab2e0b8
|
Hi @effigies, I can take on another task if needed. |
If you've got the time, there are several submodules that haven't been claimed. |
I'm working on Question: assert_raises(NotImplementedError, vi.__getitem__, (slice(None), 0))
assert_raises(NotImplementedError, vi.__setitem__, (slice(None), 0), 0)
assert_raises(NotImplementedError, vi.__delitem__, (slice(None), 0)) How to translate with pytest.raises(NotImplementedError):
vi[(slice(None), 0)]
with pytest.raises(NotImplementedError):
vi[(slice(None), 0)] = 0
with pytest.raises(NotImplementedError):
vi.__delitem__((slice(None), 0)) assert_raises(*raiser) Is there a more elegant way of this? with pytest.raises(raiser[0]):
raiser[1](*raiser[2:]) |
Hi @robbisg, I would translate these: with pytest.raises(NotImplementedError):
vi[:, 0]
with pytest.raises(NotImplementedError):
vi[:, 0] = 0
with pytest.raises(NotImplementedError):
del vi[:, 0] And for |
I'll also take nibabel.cmdline.tests. Work on it tomorrow. |
Hey @orduek, I already did this module! |
I don't know that anything needs to be done in benchmarks, except improve the docstrings. I think the next thing to do is to replace old |
@effigies - anyone is working on |
@djarecka I don't think so. Feel free. |
@effigies - I've made changes, but by mistake I push it directly to |
If somebody has time to review #891, I would appreciate it. |
Tasks
setUp()
to test whether the class name starts with_
, andpytest.skip()
._
#871pytest.deprecated_call()
andpytest.warns()
instead ofclear_and_catch_warning
, when sensible. See TEST: Drop nose for pytest #865 (comment) and TEST: Drop nose for pytest #865 (comment).Some principles:
assert_almost_equal
.Original post follows:
Summary
nose
is finally going to start failing on Python 3.9 due to some standard library API changes.Python 3.9.0 is due to be released in October, but we might as well get out ahead of it. We don't need to rush, so I'm going to target the nibabel 3.1.0 release.
I put out a call on Twitter to see if anybody wanted to sprint on this, and got responses from @arokem, @chrisgorgo, @orduek, @robbisg and @anibalsolon (thanks to all for having the same handle on GitHub and Twitter).
This thread exists to coordinate the sprint.
Status
@djarecka and @chrisgorgo started on conversion in November:
There have been some changes in the tests since #840 was started, so it requires merging/rebasing.
Plans
To facilitate the transition, I've started the
pytest
branch, which is #840's commits, rebased on master.The first thing to do is to identify all remaining tasks. Off the top of my head we need to:
nose.tools
.unittest
features, which pytest should be able to handle transparently.Logistics
Let's set at least one definite window that people want to be actively working on this and where I can commit to being more responsive to keep things from stalling out. We don't all need to align, but it would probably be best for me if there isn't a separate window for each participant.
Would it be useful to attempt to do this (semi-)synchronously, and use a chat room? Or would people rather go through the usual process of creating issues and pull requests?
The text was updated successfully, but these errors were encountered: