1
00:00:05,200 --> 00:00:07,470
as I mentioned towards the end of the

2
00:00:07,470 --> 00:00:10,240
last video you can also create your own

3
00:00:10,240 --> 00:00:12,700
exceptions their just objects after all

4
00:00:12,700 --> 00:00:15,490
so we can provide more immediate

5
00:00:15,490 --> 00:00:17,470
feedback to the developers using our duck

6
00:00:17,470 --> 00:00:19,360
module so let's go back and have a look

7
00:00:19,360 --> 00:00:23,740
at the add_duck method you

8
00:00:23,740 --> 00:00:26,290
can see that their on line 50 now we

9
00:00:26,290 --> 00:00:28,180
provided a hint that it should be

10
00:00:28,180 --> 00:00:31,450
passing a duck or subclass of duck now

11
00:00:31,450 --> 00:00:33,790
if we extended the duck class to create

12
00:00:33,790 --> 00:00:37,290
a mallard class perhaps then a mallard is

13
00:00:37,290 --> 00:00:39,840
also a duck but we can do better than

14
00:00:39,840 --> 00:00:42,220
this we can check the type of the

15
00:00:42,220 --> 00:00:45,040
argument that's past and show you how to

16
00:00:45,040 --> 00:00:48,420
do that so we're going to type in here

17
00:00:48,420 --> 00:00:54,060
in the add duck method...

18
00:00:54,060 --> 00:00:58,350
...

19
00:00:58,350 --> 00:01:01,200
...if we go

20
00:01:01,200 --> 00:01:06,240
back to our file again and run it this

21
00:01:06,240 --> 00:01:08,530
time we get all seven ducks taking off

22
00:01:08,530 --> 00:01:09,960
and there's no exception

23
00:01:09,960 --> 00:01:13,300
now that's because Percy isn't a dark so

24
00:01:13,300 --> 00:01:17,740
this test on line 51 fails and Percy

25
00:01:17,740 --> 00:01:19,600
doesn't get added to the list and

26
00:01:19,600 --> 00:01:20,850
incidentally make sure you use the

27
00:01:20,850 --> 00:01:23,620
lowercase D in the first duck this part

28
00:01:23,620 --> 00:01:26,980
here on line 51 if you used a capital D

29
00:01:26,980 --> 00:01:28,890
there then you checking the type of the

30
00:01:28,890 --> 00:01:32,310
duck class which is a class so the

31
00:01:32,310 --> 00:01:35,050
type function returns the type

32
00:01:35,050 --> 00:01:37,380
of an object so here we are testing that the

33
00:01:37,380 --> 00:01:38,980
duck that's been passed to our method

34
00:01:38,980 --> 00:01:41,800
really is a duck never do this

35
00:01:41,800 --> 00:01:43,600
now not only is this is not python

36
00:01:43,600 --> 00:01:45,520
it's also wrong

37
00:01:45,520 --> 00:01:48,270
now it's an obvious thing to do and if

38
00:01:48,270 --> 00:01:50,590
you used to programming in java you

39
00:01:50,590 --> 00:01:54,090
probably expected to work but to see why

40
00:01:54,090 --> 00:01:56,340
it doesn't we're going to create a mallard

41
00:01:56,340 --> 00:02:00,810
class that extends duck i'm just going

42
00:02:00,810 --> 00:02:03,060
to put it just after the penguin

43
00:02:03,060 --> 00:02:09,580
class....

44
00:02:09,580 --> 00:02:14,800
...

45
00:02:14,800 --> 00:02:17,200
....if we were really

46
00:02:17,200 --> 00:02:20,110
creating a mallard then you add some of

47
00:02:20,110 --> 00:02:23,080
the properties of a mallard but here we're

48
00:02:23,080 --> 00:02:24,460
just demonstrating that the previous

49
00:02:24,460 --> 00:02:27,280
code fails with sub classes so going back

50
00:02:27,280 --> 00:02:30,460
to the migration .py file we need to

51
00:02:30,460 --> 00:02:33,040
change your definition and will actually

52
00:02:33,040 --> 00:02:35,950
change for percy here and we'll put

53
00:02:35,950 --> 00:02:38,890
Percy equals duck . mallard this time

54
00:02:38,890 --> 00:02:46,630
let's run this and you can see that we

55
00:02:46,630 --> 00:02:48,250
still only get the seven ducks flying

56
00:02:48,250 --> 00:02:50,500
so this type function that we're talking

57
00:02:50,500 --> 00:02:56,590
about now on line 55 returns the exact

58
00:02:56,590 --> 00:02:59,170
type of an object and we check to see if

59
00:02:59,170 --> 00:03:02,290
that type is duck which isn't is mallard

60
00:03:02,290 --> 00:03:05,560
in this case of the one that we set up

61
00:03:05,560 --> 00:03:09,370
for percy here on line 11 now if

62
00:03:09,370 --> 00:03:10,480
you want to do this there are

63
00:03:10,480 --> 00:03:13,360
occasionally times when you need to then

64
00:03:13,360 --> 00:03:16,230
use is instance instead of checking the

65
00:03:16,230 --> 00:03:18,760
type so let me change this duck method

66
00:03:18,760 --> 00:03:23,080
now so instead of type...

67
00:03:23,080 --> 00:03:28,210
...

68
00:03:28,210 --> 00:03:29,050
....first one is the lowercase

69
00:03:29,050 --> 00:03:31,810
version for the variable the second one

70
00:03:31,810 --> 00:03:34,840
is the actual class name and if we do

71
00:03:34,840 --> 00:03:36,160
that now that we've done that if we

72
00:03:36,160 --> 00:03:43,750
go back to our code run it again and what I

73
00:03:43,750 --> 00:03:45,010
should have done is remove this last

74
00:03:45,010 --> 00:03:48,040
part so all we really want to do at this

75
00:03:48,040 --> 00:03:49,810
point is if is instance and then in

76
00:03:49,810 --> 00:03:52,450
parentheses duck , duck now if i try

77
00:03:52,450 --> 00:03:56,010
run that this time you can see

78
00:03:56,010 --> 00:03:58,420
we've actually got all 8 ducks in the

79
00:03:58,420 --> 00:03:58,930
air

80
00:03:58,930 --> 00:04:01,390
the reason for that is this is

81
00:04:01,390 --> 00:04:04,870
is instance function so again if you must

82
00:04:04,870 --> 00:04:06,640
do this type of checking always uses this is

83
00:04:06,640 --> 00:04:08,950
instance or there's also is instance

84
00:04:08,950 --> 00:04:10,450
method if you're dealing with classes

85
00:04:10,450 --> 00:04:13,230
rather than instances of classes and

86
00:04:13,230 --> 00:04:15,340
don't check the type like we did earlier

87
00:04:15,340 --> 00:04:17,170
now keep in mind though it's still not

88
00:04:17,170 --> 00:04:20,500
pythonic though in Python remember we're

89
00:04:20,500 --> 00:04:21,970
not interested in whether percy is a

90
00:04:21,970 --> 00:04:22,810
duck or not

91
00:04:22,810 --> 00:04:24,540
we're only interested in wether percy

92
00:04:24,540 --> 00:04:27,310
can fly if it flies like a duck it's a

93
00:04:27,310 --> 00:04:29,910
duck now checking like this again

94
00:04:29,910 --> 00:04:32,350
is sometimes appropriate if your

95
00:04:32,350 --> 00:04:34,120
function or method requires and int for

96
00:04:34,120 --> 00:04:36,580
example it does make sense to check if

97
00:04:36,580 --> 00:04:39,550
you've got an int or subclass of int and

98
00:04:39,550 --> 00:04:41,650
yes in Python you can subclassing if

99
00:04:41,650 --> 00:04:44,650
you want to it wouldn't be practical to

100
00:04:44,650 --> 00:04:47,470
check all the behavior of an argument to

101
00:04:47,470 --> 00:04:50,080
see if it quacks like an int but when

102
00:04:50,080 --> 00:04:51,970
dealing with the most other objects the

103
00:04:51,970 --> 00:04:54,550
pythonic way is to focus on the behavior

104
00:04:54,550 --> 00:04:58,720
you want not on the type of the object so

105
00:04:58,720 --> 00:05:02,590
what we really want to do is check to

106
00:05:02,590 --> 00:05:06,190
see if the arguments gotta fly method if

107
00:05:06,190 --> 00:05:08,350
it can fly then we can add it to the

108
00:05:08,350 --> 00:05:10,840
flock so there's two steps to this first

109
00:05:10,840 --> 00:05:12,310
what we want to do is check if there's

110
00:05:12,310 --> 00:05:14,980
an attribute called fly the next we

111
00:05:14,980 --> 00:05:17,710
check to see that this is a method and

112
00:05:17,710 --> 00:05:20,350
not a data attribute so let's add the

113
00:05:20,350 --> 00:05:22,360
code for that instead

114
00:05:22,360 --> 00:05:23,830
so again we're doing this code on that

115
00:05:23,830 --> 00:05:26,800
line 55 going to change that line again

116
00:05:26,800 --> 00:05:29,680
so the first line of the add_

117
00:05:29,680 --> 00:05:32,380
duck method we're going to put....

118
00:05:32,380 --> 00:05:36,370
...

119
00:05:36,370 --> 00:05:56,860
...

120
00:05:56,860 --> 00:05:59,890
....so the get

121
00:05:59,890 --> 00:06:02,310
attributed method checks an objects

122
00:06:02,310 --> 00:06:04,600
dictionary to see if it contains the

123
00:06:04,600 --> 00:06:07,180
attribute we specify fly in this case

124
00:06:07,180 --> 00:06:09,790
now if the attribute wasn't present

125
00:06:09,790 --> 00:06:12,430
would get an error so it works very

126
00:06:12,430 --> 00:06:15,220
like a dictionaries get method by

127
00:06:15,220 --> 00:06:17,440
specifying a default value we get none

128
00:06:17,440 --> 00:06:19,420
returned instead of the error

129
00:06:19,420 --> 00:06:21,640
next we're using this callable

130
00:06:21,640 --> 00:06:23,920
function to check if the fly method is

131
00:06:23,920 --> 00:06:26,290
callable now functions and methods are

132
00:06:26,290 --> 00:06:29,680
callable data attributes aren't now that's

133
00:06:29,680 --> 00:06:31,600
not strictly true because you can't have

134
00:06:31,600 --> 00:06:34,720
a callable data attribute in python but

135
00:06:34,720 --> 00:06:36,430
if we call the fly attribute

136
00:06:36,430 --> 00:06:38,800
then our code will work so this test is

137
00:06:38,800 --> 00:06:41,530
perfectly fine and just to confirm if we

138
00:06:41,530 --> 00:06:45,250
go back and run it again we are getting

139
00:06:45,250 --> 00:06:46,900
all 8 ducks flying

140
00:06:46,900 --> 00:06:49,090
alright so let's change our percy now

141
00:06:49,090 --> 00:06:54,310
back to being a penguin again and to

142
00:06:54,310 --> 00:06:57,280
confirm this time you run it again we

143
00:06:57,280 --> 00:06:59,110
now getting seven ducks taking off

144
00:06:59,110 --> 00:07:00,940
so clearly the fact that we have

145
00:07:00,940 --> 00:07:04,270
change percy back to penguin means that

146
00:07:04,270 --> 00:07:06,580
the code that we've defined here is

147
00:07:06,580 --> 00:07:08,590
correctly figuring out that the penguin

148
00:07:08,590 --> 00:07:11,590
class hasn't got a fly method and

149
00:07:11,590 --> 00:07:13,240
not trying to call it and and

150
00:07:13,240 --> 00:07:15,130
consequently not trying to add it to our

151
00:07:15,130 --> 00:07:17,830
list so now that we've done that this is

152
00:07:17,830 --> 00:07:20,500
the pythonic way to do the test we're

153
00:07:20,500 --> 00:07:21,790
not interested in the type of the duck

154
00:07:21,790 --> 00:07:24,520
argument we are only interested in whether it

155
00:07:24,520 --> 00:07:25,900
can fly or not

156
00:07:25,900 --> 00:07:27,910
now for our purposes if it flies like a duck

157
00:07:27,910 --> 00:07:29,910
then its a duck

158
00:07:29,910 --> 00:07:31,690
now sometimes this will be an

159
00:07:31,690 --> 00:07:34,620
appropriate solution as it is often you

160
00:07:34,620 --> 00:07:36,120
want to notify the caller that

161
00:07:36,120 --> 00:07:38,370
something's going wrong and the Penguins

162
00:07:38,370 --> 00:07:41,020
been excluded from the flock now this is

163
00:07:41,020 --> 00:07:43,560
really a programming error the user of

164
00:07:43,560 --> 00:07:45,220
our module shouldn't be passing

165
00:07:45,220 --> 00:07:47,940
flightless birds to a module that deals

166
00:07:47,940 --> 00:07:51,160
with bird migration so this may be

167
00:07:51,160 --> 00:07:53,250
another place where raising an exception

168
00:07:53,250 --> 00:07:56,190
is actually appropriate let's go ahead

169
00:07:56,190 --> 00:07:58,500
and do that so if we don't add the duck

170
00:07:58,500 --> 00:08:00,220
to the flocks list let's raise an

171
00:08:00,220 --> 00:08:02,430
exception at that point we're going to

172
00:08:02,430 --> 00:08:05,430
do is put an else to the if callable

173
00:08:05,430 --> 00:08:10,500
...

174
00:08:10,500 --> 00:08:16,470
....

175
00:08:16,470 --> 00:08:31,160
....

176
00:08:31,160 --> 00:08:33,049
....so again what we're

177
00:08:33,049 --> 00:08:35,360
doing here is if we don't add the duck to

178
00:08:35,360 --> 00:08:37,039
the flocks list because we established

179
00:08:37,039 --> 00:08:39,710
that because we established that it hasn't got an

180
00:08:39,710 --> 00:08:42,140
attribute called fly and that it's not

181
00:08:42,140 --> 00:08:44,560
callable then we're going to raise this

182
00:08:44,560 --> 00:08:47,740
typeerror we saw earlier that there are

183
00:08:47,740 --> 00:08:50,050
a lot whole load of exceptions available

184
00:08:50,050 --> 00:08:51,920
so you should try and choose the most

185
00:08:51,920 --> 00:08:54,650
appropriate exception to raise here

186
00:08:54,650 --> 00:08:56,170
they're passing something that can't fly

187
00:08:56,170 --> 00:09:00,550
so a type error is a good choice and is

188
00:09:00,550 --> 00:09:02,360
also shows a valid use of the type

189
00:09:02,360 --> 00:09:05,090
function so we're not going to check what type

190
00:09:05,090 --> 00:09:07,250
something is but to provide

191
00:09:07,250 --> 00:09:08,900
information on the type of object that

192
00:09:08,900 --> 00:09:12,380
caused the problem in Python if you find

193
00:09:12,380 --> 00:09:14,050
yourself using type to check what type

194
00:09:14,050 --> 00:09:16,280
something is then step back and consider

195
00:09:16,280 --> 00:09:18,020
if there's another way to achieve what

196
00:09:18,020 --> 00:09:20,210
you're trying to do so now

197
00:09:20,210 --> 00:09:21,730
I've done that we go back to migration

198
00:09:21,730 --> 00:09:25,700
and run it again you can see we've got

199
00:09:25,700 --> 00:09:28,520
an exception here cannot add duck are you

200
00:09:28,520 --> 00:09:30,290
sure it's not a penguin and probably

201
00:09:30,290 --> 00:09:34,880
got an extra space that I could fix up just to

202
00:09:34,880 --> 00:09:37,300
be clear run again

203
00:09:37,300 --> 00:09:40,160
okay so we are now getting an exception

204
00:09:40,160 --> 00:09:43,040
raised before the migration is started

205
00:09:43,040 --> 00:09:45,230
at the time the flightless penguin is

206
00:09:45,230 --> 00:09:47,660
added to the list now the stack trace

207
00:09:47,660 --> 00:09:50,720
here is useful and shows where the

208
00:09:50,720 --> 00:09:52,850
exception was raised as well as the call

209
00:09:52,850 --> 00:09:56,230
that originated the error now this error

210
00:09:56,230 --> 00:09:57,980
would be picked up straightaway testing

211
00:09:57,980 --> 00:10:00,020
and the programmer can modify the code

212
00:10:00,020 --> 00:10:02,540
to remove the bug so it's really

213
00:10:02,540 --> 00:10:04,910
easy to stick to the Python principle of

214
00:10:04,910 --> 00:10:06,950
if it quacks like a duck while still

215
00:10:06,950 --> 00:10:08,630
making functions and methods type safe

216
00:10:08,630 --> 00:10:11,920
for one of a better expression now

217
00:10:11,920 --> 00:10:13,460
there's another reason you may want to

218
00:10:13,460 --> 00:10:15,650
raise exceptions and that's in order to

219
00:10:15,650 --> 00:10:18,920
test your exception handlers now to see

220
00:10:18,920 --> 00:10:20,570
this working we're going to fix the

221
00:10:20,570 --> 00:10:22,420
code so that Percy does have a fly

222
00:10:22,420 --> 00:10:24,610
method in fact i'm going to give him an

223
00:10:24,610 --> 00:10:27,230
aviat method instead and it'll be

224
00:10:27,230 --> 00:10:28,600
clear why shortly

225
00:10:28,600 --> 00:10:33,770
let's go back and do that we're going to

226
00:10:33,770 --> 00:10:35,230
add another method down here for the

227
00:10:35,230 --> 00:10:39,600
penguin class...

228
00:10:39,600 --> 00:10:45,450
....

229
00:10:45,450 --> 00:11:13,470
....

230
00:11:13,470 --> 00:11:19,110
now going to explain a bit more about

231
00:11:19,110 --> 00:11:20,580
that but first i'm going to run the

232
00:11:20,580 --> 00:11:23,130
program to make sure that works let's do

233
00:11:23,130 --> 00:11:28,740
that you can see that that's work fine

234
00:11:28,740 --> 00:11:29,970
we've got I won the lottery and bought

235
00:11:29,970 --> 00:11:31,710
a lear jet and haven't got an exception

236
00:11:31,710 --> 00:11:33,840
anymore and going back to our code

237
00:11:33,840 --> 00:11:36,330
looking at the init method here on our

238
00:11:36,330 --> 00:11:39,480
line 35 we created a new data

239
00:11:39,480 --> 00:11:42,510
attribute called fly and we assign it to our

240
00:11:42,510 --> 00:11:45,000
reference to the aviate method and I

241
00:11:45,000 --> 00:11:46,350
mentioned not to include the opening and

242
00:11:46,350 --> 00:11:48,840
closing parenthesis after aviate and

243
00:11:48,840 --> 00:11:50,940
noting that IntelliJ actually tried to

244
00:11:50,940 --> 00:11:52,890
add them for us which would have

245
00:11:52,890 --> 00:11:54,750
prevented this from working properly so

246
00:11:54,750 --> 00:11:56,700
by removing the parentheses we're adding

247
00:11:56,700 --> 00:11:59,580
just a reference to the aviate method that

248
00:11:59,580 --> 00:12:03,030
this code here on line 36 now everything

249
00:12:03,030 --> 00:12:05,550
in python is an object even functions

250
00:12:05,550 --> 00:12:08,010
and methods so you can assign a method

251
00:12:08,010 --> 00:12:10,380
to a variable then call that variable

252
00:12:10,380 --> 00:12:13,020
self.fly in this case just like you

253
00:12:13,020 --> 00:12:15,300
called a method that points to now we

254
00:12:15,300 --> 00:12:17,070
saw that when we created the deal_

255
00:12:17,070 --> 00:12:19,110
_dealer and deal_player

256
00:12:19,110 --> 00:12:21,450
functions and assign them to the command

257
00:12:21,450 --> 00:12:24,030
attribute or our tk buttons all the way back in

258
00:12:24,030 --> 00:12:26,610
the blackjack game in Section 11

259
00:12:26,610 --> 00:12:29,190
alright so back to raising exceptions for

260
00:12:29,190 --> 00:12:32,280
testing we've now got a working program

261
00:12:32,280 --> 00:12:35,400
that contains exception handlers so how

262
00:12:35,400 --> 00:12:37,080
do we test that the exception handlers

263
00:12:37,080 --> 00:12:38,520
are working correctly

264
00:12:38,520 --> 00:12:40,890
well with a program like this we could

265
00:12:40,890 --> 00:12:42,810
do it by passing inappropriate arguments

266
00:12:42,810 --> 00:12:45,000
to the add_duck method and

267
00:12:45,000 --> 00:12:47,130
we've seen that working but sometimes

268
00:12:47,130 --> 00:12:49,410
getting real exceptions isn't that easy

269
00:12:49,410 --> 00:12:51,550
simulating something like

270
00:12:51,550 --> 00:12:53,710
perhaps a disk full exception that

271
00:12:53,710 --> 00:12:56,170
prevents writing data to a file is possible

272
00:12:56,170 --> 00:12:58,150
but very fiddly to set up

273
00:12:58,150 --> 00:12:59,530
you may also want to respond to

274
00:12:59,530 --> 00:13:01,340
exceptions if the network link goes down

275
00:13:01,340 --> 00:13:03,670
while you're downloading data and if you

276
00:13:03,670 --> 00:13:06,400
have a test team then probably they will do

277
00:13:06,400 --> 00:13:07,760
things like switching off the router

278
00:13:07,760 --> 00:13:09,520
while downloading to make sure your

279
00:13:09,520 --> 00:13:11,570
program kept gracefully like situations

280
00:13:11,570 --> 00:13:14,270
like that but before it gets to the test

281
00:13:14,270 --> 00:13:16,330
team you can test your exception

282
00:13:16,330 --> 00:13:19,460
handling by raising your own exception in

283
00:13:19,460 --> 00:13:21,140
the code that's protected by a try block

284
00:13:21,140 --> 00:13:23,860
so going back to our migrate method of

285
00:13:23,860 --> 00:13:31,660
the flock in here let's now raise an

286
00:13:31,660 --> 00:13:35,470
exception inside the for loop i'm coming

287
00:13:35,470 --> 00:13:38,450
down here to the try then the ducks duck

288
00:13:38,450 --> 00:13:42,400
. fly and after here what we want to do is

289
00:13:42,400 --> 00:13:45,710
you want to put raise attribute error

290
00:13:45,710 --> 00:13:52,360
...

291
00:13:52,360 --> 00:13:59,530
....

292
00:13:59,530 --> 00:14:06,100
....if we test this now you can see that

293
00:14:06,100 --> 00:14:09,700
i'm basically getting this exception

294
00:14:09,700 --> 00:14:14,770
its raise after each duck flies and we

295
00:14:14,770 --> 00:14:16,630
can see the one duck down message after

296
00:14:16,630 --> 00:14:17,710
each duck

297
00:14:17,710 --> 00:14:19,630
once all the ducks has been process the

298
00:14:19,630 --> 00:14:21,310
exception is raised and then get the

299
00:14:21,310 --> 00:14:23,830
stack trace that's a useful technique

300
00:14:23,830 --> 00:14:26,800
for testing your exception handlers just

301
00:14:26,800 --> 00:14:28,480
raise an exception that you're handling

302
00:14:28,480 --> 00:14:31,840
in the code inside the try block and

303
00:14:31,840 --> 00:14:36,100
again that's this code here on line 73 now

304
00:14:36,100 --> 00:14:37,780
one final thing before I end this video

305
00:14:37,780 --> 00:14:40,390
if you forget about that test exception

306
00:14:40,390 --> 00:14:42,700
and release your code things aren't going to

307
00:14:42,700 --> 00:14:46,540
go well so what you can do is get

308
00:14:46,540 --> 00:14:48,400
IntelliJ to help make sure you remember

309
00:14:48,400 --> 00:14:50,590
to remove the test code and the way to

310
00:14:50,590 --> 00:14:52,300
do that would be to put a comment on the

311
00:14:52,300 --> 00:14:58,720
line hash...

312
00:14:58,720 --> 00:15:02,530
....adding a comment that contains

313
00:15:02,530 --> 00:15:04,150
the word to do and it's not

314
00:15:04,150 --> 00:15:06,730
case-sensitive causes IntelliJ to track

315
00:15:06,730 --> 00:15:08,740
it as an item that needs to be done

316
00:15:08,740 --> 00:15:10,900
note that the comment from the to do

317
00:15:10,900 --> 00:15:13,600
here appears in a different color depending

318
00:15:13,600 --> 00:15:16,210
on your choice of theme it'll be

319
00:15:16,210 --> 00:15:18,250
probably blue or in my case it's sort of

320
00:15:18,250 --> 00:15:21,250
a yellow so that's the to do but

321
00:15:21,250 --> 00:15:23,440
also what we can do is we can bring up a

322
00:15:23,440 --> 00:15:25,810
tab to see all the to dos in our

323
00:15:25,810 --> 00:15:27,460
projects i'm close down the run window

324
00:15:27,460 --> 00:15:30,460
this is to do down here that down the

325
00:15:30,460 --> 00:15:32,530
bottom left click on that and that

326
00:15:32,530 --> 00:15:35,230
actually shows us all that to do entries

327
00:15:35,230 --> 00:15:37,180
and then clicking on them to be taken to

328
00:15:37,180 --> 00:15:38,890
the relevant bit of code so even though

329
00:15:38,890 --> 00:15:40,690
it's on the screen i can click on there

330
00:15:40,690 --> 00:15:42,490
and it just shows on the screen pretty

331
00:15:42,490 --> 00:15:43,090
cool

332
00:15:43,090 --> 00:15:44,950
alright so that's the end of our

333
00:15:44,950 --> 00:15:47,440
discussion on exceptions in python in

334
00:15:47,440 --> 00:15:48,550
the next video we're going to get back

335
00:15:48,550 --> 00:15:50,860
to databases but we are gonna start making

336
00:15:50,860 --> 00:15:52,540
use of exception handling in our code

337
00:15:52,540 --> 00:15:59,040
see you in the next video

