Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Juan Christian
On Sun, Sep 21, 2014 at 10:13 PM, Steven D'Aprano wrote: > > Have patience, we're not on 24/7 duty and you don't have a SLA (Service > Level Agreement) with us. > > Normally it is considered polite to wait at least one day before sending > a reminder, not six hours. Although we have list members a

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Steven D'Aprano
On Sun, Sep 21, 2014 at 03:11:02PM -0300, Juan Christian wrote: > Anyone?​ Have patience, we're not on 24/7 duty and you don't have a SLA (Service Level Agreement) with us. Normally it is considered polite to wait at least one day before sending a reminder, not six hours. Although we have list

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Juan Christian
Thanks Danny, indeed, the problem was in these confusing names. The problem was here: Class Episode > s = season The fix: s = season.number ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mai

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Juan Christian
On Sun, Sep 21, 2014 at 4:21 PM, Joel Goldstick wrote: > > Shouldn't it be: Season(ID, season, serie)? No, we always have to have 'self' in the first arg. On Sun, Sep 21, 2014 at 4:25 PM, Danny Yoo wrote: > > Please treat email as asynchronous: sometimes you'll get a response > within minute

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Danny Yoo
On Sun, Sep 21, 2014 at 11:11 AM, Juan Christian wrote: > Anyone? Please treat email as asynchronous: sometimes you'll get a response within minutes, but sometimes it takes a little longer. Reading the question quickly... I can't answer this too carefully. I haven't even had breakfast or lunch

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Joel Goldstick
On Sun, Sep 21, 2014 at 2:36 PM, Juan Christian wrote: > On Sun, Sep 21, 2014 at 3:28 PM, Joel Goldstick > wrote: >> >> You are calling Season with different parameters than it was defined to >> accept. > > > No, I'm not. > > Season > def __init__(self, ID, season, serie) > > and I'm calling it w

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Juan Christian
On Sun, Sep 21, 2014 at 3:28 PM, Joel Goldstick wrote: > > You are calling Season with different parameters than it was defined to > accept. No, I'm not. Season > def __init__(self, ID, season, serie) and I'm calling it with Season(ID, season, self), I'm giving everything needed, don't I?

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Joel Goldstick
On Sun, Sep 21, 2014 at 10:18 AM, Juan Christian wrote: > I have a ' self.size = json['number_of_seasons'] ' that equals 5 (already > checked), the problem is that the API have some series with special seasons, > aka, season_number = 0, and I don't want to get those. > > I have the following list

Re: [Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Juan Christian
Anyone?​ ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor

[Tutor] Python 3: List Comprehensions + range

2014-09-21 Thread Juan Christian
I have a ' self.size = json['number_of_seasons'] ' that equals 5 (already checked), the problem is that the API have some series with special seasons, aka, season_number = 0, and I don't want to get those. I have the following list comp: self.season = [Season(ID, season, self) for season in range(