-
Notifications
You must be signed in to change notification settings - Fork 263
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
limit is broken #3
Comments
Just a few more examples to highlight the unexpected results from this limit function. No limit produces 8 results: for p in q.sort('passing_yds').as_plays():
print p
> (NE, OWN 17, Q2, 1 and 10) (9:56) (Shotgun) T.Brady pass short left to S.Vereen for 83 yards, TOUCHDOWN.
> (NE, OWN 37, Q3, 3 and 10) (10:00) (Shotgun) T.Brady pass deep middle to D.Stallworth for 63 yards, TOUCHDOWN. NE 12-Brady 18th career game with 4+ TD passes, passing Johnny Unitas for 4th most all-time.
> (NE, OWN 21, Q1, 1 and 10) (9:32) (No Huddle) T.Brady pass deep left to W.Welker to BAL 20 for 59 yards (B.Pollard).
> (NE, OWN 44, Q2, 3 and 5) (3:17) (Shotgun) T.Brady pass deep left to J.Edelman for 56 yards, TOUCHDOWN.
> (NE, OWN 18, Q4, 1 and 10) (9:18) (No Huddle, Shotgun) T.Brady pass deep right to B.Lloyd to SF 29 for 53 yards (C.Culliver).
> (NE, OPP 46, Q1, 1 and 10) (5:59) (No Huddle, Shotgun) T.Brady pass deep left to W.Welker for 46 yards, TOUCHDOWN.
> (NE, OWN 33, Q1, 2 and 5) (8:57) (Shotgun) T.Brady pass deep right to R.Gronkowski to BUF 26 for 41 yards (J.Rogers). Caught at BUF 32, slanting to sideline.
> (NE, OPP 44, Q3, 2 and 1) (2:09) (No Huddle, Shotgun) T.Brady pass deep right to M.Hoomanawanui to SF 3 for 41 yards (D.Whitner).
[Finished in 0.7s]
for p in q.sort('passing_yds').limit(1).as_plays():
print p
[Finished in 0.5s]
for p in q.sort('passing_yds').limit(10).as_plays():
print p
> (NE, OWN 17, Q2, 1 and 10) (9:56) (Shotgun) T.Brady pass short left to S.Vereen for 83 yards, TOUCHDOWN.
[Finished in 0.5s]
for p in q.sort('passing_yds').limit(200).as_plays():
print p
> (NE, OWN 17, Q2, 1 and 10) (9:56) (Shotgun) T.Brady pass short left to S.Vereen for 83 yards, TOUCHDOWN.
> (NE, OWN 37, Q3, 3 and 10) (10:00) (Shotgun) T.Brady pass deep middle to D.Stallworth for 63 yards, TOUCHDOWN. NE 12-Brady 18th career game with 4+ TD passes, passing Johnny Unitas for 4th most all-time.
> (NE, OWN 21, Q1, 1 and 10) (9:32) (No Huddle) T.Brady pass deep left to W.Welker to BAL 20 for 59 yards (B.Pollard).
> (NE, OWN 44, Q2, 3 and 5) (3:17) (Shotgun) T.Brady pass deep left to J.Edelman for 56 yards, TOUCHDOWN.
> (NE, OWN 18, Q4, 1 and 10) (9:18) (No Huddle, Shotgun) T.Brady pass deep right to B.Lloyd to SF 29 for 53 yards (C.Culliver).
> (NE, OPP 46, Q1, 1 and 10) (5:59) (No Huddle, Shotgun) T.Brady pass deep left to W.Welker for 46 yards, TOUCHDOWN.
[Finished in 0.6s] |
Thanks for the extra examples. This isn't going to be a simple fix, unfortunately. |
I think I fixed this unknowingly. If I had to guess, I think the commit is 51468a6 in |
This code
produces this output:
But it should be:
The text was updated successfully, but these errors were encountered: