-
Notifications
You must be signed in to change notification settings - Fork 0
/
out_example_server.py.txt
542 lines (542 loc) · 31.4 KB
/
out_example_server.py.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
Module(body=[<_ast.Expr object at 0x000002150A8F42E8>, <_ast.Expr object at 0x000002150A8F4358>, <_ast.Import object at 0x000002150A8F43C8>, <_ast.Import object at 0x000002150A8F4470>, <_ast.Import object at 0x000002150A8F44E0>, <_ast.Import object at 0x000002150A8F4550>, <_ast.Import object at 0x000002150A8F45C0>, <_ast.Assign object at 0x000002150A8F4630>, <_ast.Assign object at 0x000002150A8F4898>, <_ast.Assign object at 0x000002150A8F4940>, <_ast.Assign object at 0x000002150A8F49E8>, <_ast.Expr object at 0x000002150A8F4A90>, <_ast.Expr object at 0x000002150A8F4C18>, <_ast.Assign object at 0x000002150A8F4D30>, <_ast.Assign object at 0x000002150A8F4DD8>, <_ast.FunctionDef object at 0x000002150A8F4E80>, <_ast.FunctionDef object at 0x000002150A98D7F0>, <_ast.FunctionDef object at 0x000002150A98E6A0>, <_ast.Assign object at 0x000002150A993A58>, <_ast.Expr object at 0x000002150A993B00>, <_ast.Expr object at 0x000002150A993CC0>, <_ast.Try object at 0x000002150A993E48>])
Expr(value=Str(s='\n\tPython3 Chat Server\n'))
Str(s='\n\tPython3 Chat Server\n')
Expr(value=Str(s=' This is another comment using a multiline '))
Str(s=' This is another comment using a multiline ')
Import(names=[<_ast.alias object at 0x000002150A8F4400>])
alias(name='socket', asname=None)
Import(names=[<_ast.alias object at 0x000002150A8F44A8>])
alias(name='threading', asname=None)
Import(names=[<_ast.alias object at 0x000002150A8F4518>])
alias(name='sys', asname=None)
Import(names=[<_ast.alias object at 0x000002150A8F4588>])
alias(name='random', asname=None)
Import(names=[<_ast.alias object at 0x000002150A8F45F8>])
alias(name='time', asname=None)
Assign(targets=[<_ast.Name object at 0x000002150A8F4668>], value=Call(func=Attribute(value=Name(id='socket', ctx=Load()), attr='socket', ctx=Load()), args=[<_ast.Attribute object at 0x000002150A8F47B8>, <_ast.Attribute object at 0x000002150A8F4828>], keywords=[]))
Name(id='s', ctx=Store())
Store()
Call(func=Attribute(value=Name(id='socket', ctx=Load()), attr='socket', ctx=Load()), args=[<_ast.Attribute object at 0x000002150A8F47B8>, <_ast.Attribute object at 0x000002150A8F4828>], keywords=[])
Attribute(value=Name(id='socket', ctx=Load()), attr='socket', ctx=Load())
Name(id='socket', ctx=Load())
Load()
Load()
Attribute(value=Name(id='socket', ctx=Load()), attr='AF_INET', ctx=Load())
Name(id='socket', ctx=Load())
Load()
Load()
Attribute(value=Name(id='socket', ctx=Load()), attr='SOCK_STREAM', ctx=Load())
Name(id='socket', ctx=Load())
Load()
Load()
Assign(targets=[<_ast.Name object at 0x000002150A8F48D0>], value=Str(s='127.0.0.1'))
Name(id='ip', ctx=Store())
Store()
Str(s='127.0.0.1')
Assign(targets=[<_ast.Name object at 0x000002150A8F4978>], value=Num(n=1313))
Name(id='port', ctx=Store())
Store()
Num(n=1313)
Assign(targets=[<_ast.Name object at 0x000002150A8F4A20>], value=Num(n=4096))
Name(id='buffer_size', ctx=Store())
Store()
Num(n=4096)
Expr(value=Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='bind', ctx=Load()), args=[<_ast.Tuple object at 0x000002150A8F4B70>], keywords=[]))
Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='bind', ctx=Load()), args=[<_ast.Tuple object at 0x000002150A8F4B70>], keywords=[])
Attribute(value=Name(id='s', ctx=Load()), attr='bind', ctx=Load())
Name(id='s', ctx=Load())
Load()
Load()
Tuple(elts=[<_ast.Name object at 0x000002150A8F4BA8>, <_ast.Name object at 0x000002150A8F4BE0>], ctx=Load())
Name(id='ip', ctx=Load())
Load()
Name(id='port', ctx=Load())
Load()
Load()
Expr(value=Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='listen', ctx=Load()), args=[<_ast.Num object at 0x000002150A8F4CF8>], keywords=[]))
Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='listen', ctx=Load()), args=[<_ast.Num object at 0x000002150A8F4CF8>], keywords=[])
Attribute(value=Name(id='s', ctx=Load()), attr='listen', ctx=Load())
Name(id='s', ctx=Load())
Load()
Load()
Num(n=5)
Assign(targets=[<_ast.Name object at 0x000002150A8F4D68>], value=Num(n=0))
Name(id='flag', ctx=Store())
Store()
Num(n=0)
Assign(targets=[<_ast.Name object at 0x000002150A8F4E10>], value=List(elts=[], ctx=Load()))
Name(id='clientConnections', ctx=Store())
Store()
List(elts=[], ctx=Load())
Load()
FunctionDef(name='GetRandomName', args=arguments(args=[], vararg=None, kwonlyargs=[], kw_defaults=[], kwarg=None, defaults=[]), body=[<_ast.Expr object at 0x000002150A8F4F60>, <_ast.Assign object at 0x000002150A98D198>, <_ast.Assign object at 0x000002150A98D390>, <_ast.Assign object at 0x000002150A98D518>, <_ast.Return object at 0x000002150A98D748>], decorator_list=[], returns=None)
arguments(args=[], vararg=None, kwonlyargs=[], kw_defaults=[], kwarg=None, defaults=[])
Expr(value=Call(func=Attribute(value=Name(id='random', ctx=Load()), attr='seed', ctx=Load()), args=[<_ast.Call object at 0x000002150A98D080>], keywords=[]))
Call(func=Attribute(value=Name(id='random', ctx=Load()), attr='seed', ctx=Load()), args=[<_ast.Call object at 0x000002150A98D080>], keywords=[])
Attribute(value=Name(id='random', ctx=Load()), attr='seed', ctx=Load())
Name(id='random', ctx=Load())
Load()
Load()
Call(func=Name(id='int', ctx=Load()), args=[<_ast.Call object at 0x000002150A98D0F0>], keywords=[])
Name(id='int', ctx=Load())
Load()
Call(func=Attribute(value=Name(id='time', ctx=Load()), attr='time', ctx=Load()), args=[], keywords=[])
Attribute(value=Name(id='time', ctx=Load()), attr='time', ctx=Load())
Name(id='time', ctx=Load())
Load()
Load()
Assign(targets=[<_ast.Name object at 0x000002150A98D1D0>], value=List(elts=[<_ast.Str object at 0x000002150A98D240>, <_ast.Str object at 0x000002150A98D278>, <_ast.Str object at 0x000002150A98D2B0>, <_ast.Str object at 0x000002150A98D2E8>, <_ast.Str object at 0x000002150A98D320>, <_ast.Str object at 0x000002150A98D358>], ctx=Load()))
Name(id='names', ctx=Store())
Store()
List(elts=[<_ast.Str object at 0x000002150A98D240>, <_ast.Str object at 0x000002150A98D278>, <_ast.Str object at 0x000002150A98D2B0>, <_ast.Str object at 0x000002150A98D2E8>, <_ast.Str object at 0x000002150A98D320>, <_ast.Str object at 0x000002150A98D358>], ctx=Load())
Str(s='Bob')
Str(s='Alice')
Str(s='Eve')
Str(s='Trudy')
Str(s='Pjotr')
Str(s='Anon')
Load()
Assign(targets=[<_ast.Name object at 0x000002150A98D3C8>], value=Call(func=Attribute(value=Name(id='random', ctx=Load()), attr='randint', ctx=Load()), args=[<_ast.Num object at 0x000002150A98D4A8>, <_ast.Num object at 0x000002150A98D4E0>], keywords=[]))
Name(id='number', ctx=Store())
Store()
Call(func=Attribute(value=Name(id='random', ctx=Load()), attr='randint', ctx=Load()), args=[<_ast.Num object at 0x000002150A98D4A8>, <_ast.Num object at 0x000002150A98D4E0>], keywords=[])
Attribute(value=Name(id='random', ctx=Load()), attr='randint', ctx=Load())
Name(id='random', ctx=Load())
Load()
Load()
Num(n=1000)
Num(n=9999)
Assign(targets=[<_ast.Name object at 0x000002150A98D550>], value=BinOp(op=Add()))
Name(id='name', ctx=Store())
Store()
BinOp(op=Add())
Call(func=Attribute(value=Name(id='random', ctx=Load()), attr='choice', ctx=Load()), args=[<_ast.Name object at 0x000002150A98D668>], keywords=[])
Attribute(value=Name(id='random', ctx=Load()), attr='choice', ctx=Load())
Name(id='random', ctx=Load())
Load()
Load()
Name(id='names', ctx=Load())
Load()
Add()
Call(func=Name(id='str', ctx=Load()), args=[<_ast.Name object at 0x000002150A98D710>], keywords=[])
Name(id='str', ctx=Load())
Load()
Name(id='number', ctx=Load())
Load()
Return(value=Name(id='name', ctx=Load()))
Name(id='name', ctx=Load())
Load()
FunctionDef(name='BroadcastMessage', args=arguments(args=[<_ast.arg object at 0x000002150A98D860>], vararg=None, kwonlyargs=[], kw_defaults=[], kwarg=None, defaults=[]), body=[<_ast.Assign object at 0x000002150A98D898>, <_ast.For object at 0x000002150A98D940>, <_ast.For object at 0x000002150A98E470>], decorator_list=[], returns=None)
arguments(args=[<_ast.arg object at 0x000002150A98D860>], vararg=None, kwonlyargs=[], kw_defaults=[], kwarg=None, defaults=[])
arg(arg='aMessage', annotation=None)
Assign(targets=[<_ast.Name object at 0x000002150A98D8D0>], value=List(elts=[], ctx=Load()))
Name(id='socketsToRemove', ctx=Store())
Store()
List(elts=[], ctx=Load())
Load()
For(target=Name(id='sock', ctx=Store()), iter=Name(id='clientConnections', ctx=Load()), body=[<_ast.Try object at 0x000002150A98D9E8>], orelse=[])
Name(id='sock', ctx=Store())
Store()
Name(id='clientConnections', ctx=Load())
Load()
Try(body=[<_ast.Expr object at 0x000002150A98DA20>], handlers=[<_ast.ExceptHandler object at 0x000002150A98DD68>], orelse=[], finalbody=[])
Expr(value=Call(func=Attribute(value=Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load()), attr='sendto', ctx=Load()), args=[<_ast.Call object at 0x000002150A98DBA8>, <_ast.Subscript object at 0x000002150A98DC88>], keywords=[]))
Call(func=Attribute(value=Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load()), attr='sendto', ctx=Load()), args=[<_ast.Call object at 0x000002150A98DBA8>, <_ast.Subscript object at 0x000002150A98DC88>], keywords=[])
Attribute(value=Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load()), attr='sendto', ctx=Load())
Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load())
Name(id='sock', ctx=Load())
Load()
Index(value=Num(n=0))
Num(n=0)
Load()
Load()
Call(func=Attribute(value=Name(id='aMessage', ctx=Load()), attr='encode', ctx=Load()), args=[<_ast.Str object at 0x000002150A98DC50>], keywords=[])
Attribute(value=Name(id='aMessage', ctx=Load()), attr='encode', ctx=Load())
Name(id='aMessage', ctx=Load())
Load()
Load()
Str(s='utf-8')
Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=1)), ctx=Load())
Name(id='sock', ctx=Load())
Load()
Index(value=Num(n=1))
Num(n=1)
Load()
ExceptHandler(type=Name(id='Exception', ctx=Load()), name='ex', body=[<_ast.Expr object at 0x000002150A98DDD8>, <_ast.Expr object at 0x000002150A98DF60>, <_ast.Expr object at 0x000002150A98E160>, <_ast.Expr object at 0x000002150A98E2E8>, <_ast.Continue object at 0x000002150A98E400>])
Name(id='Exception', ctx=Load())
Load()
Expr(value=Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A98DE80>], keywords=[]))
Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A98DE80>], keywords=[])
Name(id='print', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='Failed to broadcast to client: {}'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A98DF28>], keywords=[])
Attribute(value=Str(s='Failed to broadcast to client: {}'), attr='format', ctx=Load())
Str(s='Failed to broadcast to client: {}')
Load()
Name(id='ex', ctx=Load())
Load()
Expr(value=Call(func=Attribute(value=Name(id='socketsToRemove', ctx=Load()), attr='append', ctx=Load()), args=[<_ast.Subscript object at 0x000002150A98E080>], keywords=[]))
Call(func=Attribute(value=Name(id='socketsToRemove', ctx=Load()), attr='append', ctx=Load()), args=[<_ast.Subscript object at 0x000002150A98E080>], keywords=[])
Attribute(value=Name(id='socketsToRemove', ctx=Load()), attr='append', ctx=Load())
Name(id='socketsToRemove', ctx=Load())
Load()
Load()
Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=2)), ctx=Load())
Name(id='sock', ctx=Load())
Load()
Index(value=Num(n=2))
Num(n=2)
Load()
Expr(value=Call(func=Attribute(value=Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load()), attr='close', ctx=Load()), args=[], keywords=[]))
Call(func=Attribute(value=Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load()), attr='close', ctx=Load()), args=[], keywords=[])
Attribute(value=Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load()), attr='close', ctx=Load())
Subscript(value=Name(id='sock', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load())
Name(id='sock', ctx=Load())
Load()
Index(value=Num(n=0))
Num(n=0)
Load()
Load()
Expr(value=Call(func=Attribute(value=Name(id='clientConnections', ctx=Load()), attr='remove', ctx=Load()), args=[<_ast.Name object at 0x000002150A98E3C8>], keywords=[]))
Call(func=Attribute(value=Name(id='clientConnections', ctx=Load()), attr='remove', ctx=Load()), args=[<_ast.Name object at 0x000002150A98E3C8>], keywords=[])
Attribute(value=Name(id='clientConnections', ctx=Load()), attr='remove', ctx=Load())
Name(id='clientConnections', ctx=Load())
Load()
Load()
Name(id='sock', ctx=Load())
Load()
Continue()
For(target=Name(id='sock', ctx=Store()), iter=Name(id='socketsToRemove', ctx=Load()), body=[<_ast.Expr object at 0x000002150A98E518>], orelse=[])
Name(id='sock', ctx=Store())
Store()
Name(id='socketsToRemove', ctx=Load())
Load()
Expr(value=Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Call object at 0x000002150A98E5C0>], keywords=[]))
Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Call object at 0x000002150A98E5C0>], keywords=[])
Name(id='BroadcastMessage', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='{} has left the chat.\n'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A98E668>], keywords=[])
Attribute(value=Str(s='{} has left the chat.\n'), attr='format', ctx=Load())
Str(s='{} has left the chat.\n')
Load()
Name(id='name', ctx=Load())
Load()
FunctionDef(name='ListenToClient', args=arguments(args=[<_ast.arg object at 0x000002150A98E710>, <_ast.arg object at 0x000002150A98E748>], vararg=None, kwonlyargs=[], kw_defaults=[], kwarg=None, defaults=[]), body=[<_ast.While object at 0x000002150A98E780>], decorator_list=[], returns=None)
arguments(args=[<_ast.arg object at 0x000002150A98E710>, <_ast.arg object at 0x000002150A98E748>], vararg=None, kwonlyargs=[], kw_defaults=[], kwarg=None, defaults=[])
arg(arg='cliSocket', annotation=None)
arg(arg='name', annotation=None)
While(test=NameConstant(value=True), body=[<_ast.Try object at 0x000002150A98E828>], orelse=[])
NameConstant(value=True)
Try(body=[<_ast.Assign object at 0x000002150A98E860>, <_ast.If object at 0x000002150A98E9B0>], handlers=[<_ast.ExceptHandler object at 0x000002150A9930F0>], orelse=[], finalbody=[])
Assign(targets=[<_ast.Name object at 0x000002150A98E898>], value=Call(func=Attribute(value=Name(id='cliSocket', ctx=Load()), attr='recv', ctx=Load()), args=[<_ast.Name object at 0x000002150A98E978>], keywords=[]))
Name(id='str_recv', ctx=Store())
Store()
Call(func=Attribute(value=Name(id='cliSocket', ctx=Load()), attr='recv', ctx=Load()), args=[<_ast.Name object at 0x000002150A98E978>], keywords=[])
Attribute(value=Name(id='cliSocket', ctx=Load()), attr='recv', ctx=Load())
Name(id='cliSocket', ctx=Load())
Load()
Load()
Name(id='buffer_size', ctx=Load())
Load()
If(test=Compare(ops=[<_ast.Gt object at 0x000002150A978CF8>], comparators=[<_ast.Num object at 0x000002150A98EB00>]), body=[<_ast.Assign object at 0x000002150A98EB38>, <_ast.Expr object at 0x000002150A98ED68>, <_ast.Expr object at 0x000002150A98EEB8>], orelse=[<_ast.Raise object at 0x000002150A98EF98>])
Compare(ops=[<_ast.Gt object at 0x000002150A978CF8>], comparators=[<_ast.Num object at 0x000002150A98EB00>])
Call(func=Name(id='len', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EA90>], keywords=[])
Name(id='len', ctx=Load())
Load()
Name(id='str_recv', ctx=Load())
Load()
Gt()
Num(n=0)
Assign(targets=[<_ast.Name object at 0x000002150A98EB70>], value=Call(func=Attribute(value=Str(s='{}: {}'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EC50>, <_ast.Call object at 0x000002150A98EC88>], keywords=[]))
Name(id='str_return', ctx=Store())
Store()
Call(func=Attribute(value=Str(s='{}: {}'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EC50>, <_ast.Call object at 0x000002150A98EC88>], keywords=[])
Attribute(value=Str(s='{}: {}'), attr='format', ctx=Load())
Str(s='{}: {}')
Load()
Name(id='name', ctx=Load())
Load()
Call(func=Attribute(value=Name(id='str_recv', ctx=Load()), attr='decode', ctx=Load()), args=[<_ast.Str object at 0x000002150A98ED30>], keywords=[])
Attribute(value=Name(id='str_recv', ctx=Load()), attr='decode', ctx=Load())
Name(id='str_recv', ctx=Load())
Load()
Load()
Str(s='utf-8')
Expr(value=Call(func=Attribute(value=Attribute(value=Name(id='sys', ctx=Load()), attr='stdout', ctx=Load()), attr='write', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EE80>], keywords=[]))
Call(func=Attribute(value=Attribute(value=Name(id='sys', ctx=Load()), attr='stdout', ctx=Load()), attr='write', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EE80>], keywords=[])
Attribute(value=Attribute(value=Name(id='sys', ctx=Load()), attr='stdout', ctx=Load()), attr='write', ctx=Load())
Attribute(value=Name(id='sys', ctx=Load()), attr='stdout', ctx=Load())
Name(id='sys', ctx=Load())
Load()
Load()
Load()
Name(id='str_return', ctx=Load())
Load()
Expr(value=Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EF60>], keywords=[]))
Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Name object at 0x000002150A98EF60>], keywords=[])
Name(id='BroadcastMessage', ctx=Load())
Load()
Name(id='str_return', ctx=Load())
Load()
Raise(exc=Call(func=Name(id='Exception', ctx=Load()), args=[<_ast.Str object at 0x000002150A993080>], keywords=[]), cause=None)
Call(func=Name(id='Exception', ctx=Load()), args=[<_ast.Str object at 0x000002150A993080>], keywords=[])
Name(id='Exception', ctx=Load())
Load()
Str(s='Connection seems to be terminated.')
ExceptHandler(type=Name(id='Exception', ctx=Load()), name='ex', body=[<_ast.Expr object at 0x000002150A993160>, <_ast.Assign object at 0x000002150A9932E8>, <_ast.For object at 0x000002150A993390>, <_ast.If object at 0x000002150A9936A0>, <_ast.Expr object at 0x000002150A993898>, <_ast.Break object at 0x000002150A993A20>])
Name(id='Exception', ctx=Load())
Load()
Expr(value=Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A993208>], keywords=[]))
Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A993208>], keywords=[])
Name(id='print', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='Client disconnected: {}'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A9932B0>], keywords=[])
Attribute(value=Str(s='Client disconnected: {}'), attr='format', ctx=Load())
Str(s='Client disconnected: {}')
Load()
Name(id='ex', ctx=Load())
Load()
Assign(targets=[<_ast.Name object at 0x000002150A993320>], value=NameConstant(value=None))
Name(id='toDelete', ctx=Store())
Store()
NameConstant(value=None)
For(target=Name(id='connection', ctx=Store()), iter=Name(id='clientConnections', ctx=Load()), body=[<_ast.If object at 0x000002150A993438>], orelse=[])
Name(id='connection', ctx=Store())
Store()
Name(id='clientConnections', ctx=Load())
Load()
If(test=Compare(ops=[<_ast.Eq object at 0x000002150A978898>], comparators=[<_ast.Name object at 0x000002150A993588>]), body=[<_ast.Assign object at 0x000002150A9935C0>, <_ast.Break object at 0x000002150A993668>], orelse=[])
Compare(ops=[<_ast.Eq object at 0x000002150A978898>], comparators=[<_ast.Name object at 0x000002150A993588>])
Subscript(value=Name(id='connection', ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load())
Name(id='connection', ctx=Load())
Load()
Index(value=Num(n=0))
Num(n=0)
Load()
Eq()
Name(id='cliSocket', ctx=Load())
Load()
Assign(targets=[<_ast.Name object at 0x000002150A9935F8>], value=Name(id='connection', ctx=Load()))
Name(id='toDelete', ctx=Store())
Store()
Name(id='connection', ctx=Load())
Load()
Break()
If(test=Compare(ops=[<_ast.NotEq object at 0x000002150A9789B0>], comparators=[<_ast.NameConstant object at 0x000002150A993748>]), body=[<_ast.Expr object at 0x000002150A993780>], orelse=[])
Compare(ops=[<_ast.NotEq object at 0x000002150A9789B0>], comparators=[<_ast.NameConstant object at 0x000002150A993748>])
Name(id='toDelete', ctx=Load())
Load()
NotEq()
NameConstant(value=None)
Expr(value=Call(func=Attribute(value=Name(id='clientConnections', ctx=Load()), attr='remove', ctx=Load()), args=[<_ast.Name object at 0x000002150A993860>], keywords=[]))
Call(func=Attribute(value=Name(id='clientConnections', ctx=Load()), attr='remove', ctx=Load()), args=[<_ast.Name object at 0x000002150A993860>], keywords=[])
Attribute(value=Name(id='clientConnections', ctx=Load()), attr='remove', ctx=Load())
Name(id='clientConnections', ctx=Load())
Load()
Load()
Name(id='toDelete', ctx=Load())
Load()
Expr(value=Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Call object at 0x000002150A993940>], keywords=[]))
Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Call object at 0x000002150A993940>], keywords=[])
Name(id='BroadcastMessage', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='{} has left the chat.\n'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A9939E8>], keywords=[])
Attribute(value=Str(s='{} has left the chat.\n'), attr='format', ctx=Load())
Str(s='{} has left the chat.\n')
Load()
Name(id='name', ctx=Load())
Load()
Break()
Assign(targets=[<_ast.Name object at 0x000002150A993A90>], value=Str(s='1.0.0 ALPHA'))
Name(id='version', ctx=Store())
Store()
Str(s='1.0.0 ALPHA')
Expr(value=Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A993BA8>], keywords=[]))
Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A993BA8>], keywords=[])
Name(id='print', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='Successfully started the server on {}:{}!'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A993C50>, <_ast.Name object at 0x000002150A993C88>], keywords=[])
Attribute(value=Str(s='Successfully started the server on {}:{}!'), attr='format', ctx=Load())
Str(s='Successfully started the server on {}:{}!')
Load()
Name(id='ip', ctx=Load())
Load()
Name(id='port', ctx=Load())
Load()
Expr(value=Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A993D68>], keywords=[]))
Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A993D68>], keywords=[])
Name(id='print', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='\tRunning version: {}'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A993E10>], keywords=[])
Attribute(value=Str(s='\tRunning version: {}'), attr='format', ctx=Load())
Str(s='\tRunning version: {}')
Load()
Name(id='version', ctx=Load())
Load()
Try(body=[<_ast.While object at 0x000002150A993E80>], handlers=[<_ast.ExceptHandler object at 0x000002150A999208>], orelse=[], finalbody=[])
While(test=NameConstant(value=True), body=[<_ast.Assign object at 0x000002150A993EF0>, <_ast.Expr object at 0x000002150A9980B8>, <_ast.Assign object at 0x000002150A9982B0>, <_ast.Assign object at 0x000002150A998390>, <_ast.Expr object at 0x000002150A998630>, <_ast.Expr object at 0x000002150A998828>, <_ast.Expr object at 0x000002150A9989B0>, <_ast.Assign object at 0x000002150A998B70>, <_ast.Expr object at 0x000002150A999128>], orelse=[])
NameConstant(value=True)
Assign(targets=[<_ast.Tuple object at 0x000002150A993F28>], value=Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='accept', ctx=Load()), args=[], keywords=[]))
Tuple(elts=[<_ast.Name object at 0x000002150A993F60>, <_ast.Name object at 0x000002150A993F98>], ctx=Store())
Name(id='connect', ctx=Store())
Store()
Name(id='addr', ctx=Store())
Store()
Store()
Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='accept', ctx=Load()), args=[], keywords=[])
Attribute(value=Name(id='s', ctx=Load()), attr='accept', ctx=Load())
Name(id='s', ctx=Load())
Load()
Load()
Expr(value=Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A998160>], keywords=[]))
Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A998160>], keywords=[])
Name(id='print', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='Connection incoming from {}'), attr='format', ctx=Load()), args=[<_ast.Call object at 0x000002150A998208>], keywords=[])
Attribute(value=Str(s='Connection incoming from {}'), attr='format', ctx=Load())
Str(s='Connection incoming from {}')
Load()
Call(func=Name(id='str', ctx=Load()), args=[<_ast.Name object at 0x000002150A998278>], keywords=[])
Name(id='str', ctx=Load())
Load()
Name(id='addr', ctx=Load())
Load()
Assign(targets=[<_ast.Name object at 0x000002150A9982E8>], value=Call(func=Name(id='GetRandomName', ctx=Load()), args=[], keywords=[]))
Name(id='name', ctx=Store())
Store()
Call(func=Name(id='GetRandomName', ctx=Load()), args=[], keywords=[])
Name(id='GetRandomName', ctx=Load())
Load()
Assign(targets=[<_ast.Name object at 0x000002150A9983C8>], value=Call(func=Attribute(value=Str(s='[SERVER] Welcome to the chat server, {}.\n\tServer version: {}\n\tPeople online: {}\n\n'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A9984A8>, <_ast.Name object at 0x000002150A9984E0>, <_ast.BinOp object at 0x000002150A998518>], keywords=[]))
Name(id='welcomeMessage', ctx=Store())
Store()
Call(func=Attribute(value=Str(s='[SERVER] Welcome to the chat server, {}.\n\tServer version: {}\n\tPeople online: {}\n\n'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A9984A8>, <_ast.Name object at 0x000002150A9984E0>, <_ast.BinOp object at 0x000002150A998518>], keywords=[])
Attribute(value=Str(s='[SERVER] Welcome to the chat server, {}.\n\tServer version: {}\n\tPeople online: {}\n\n'), attr='format', ctx=Load())
Str(s='[SERVER] Welcome to the chat server, {}.\n\tServer version: {}\n\tPeople online: {}\n\n')
Load()
Name(id='name', ctx=Load())
Load()
Name(id='version', ctx=Load())
Load()
BinOp(op=Add())
Call(func=Name(id='len', ctx=Load()), args=[<_ast.Name object at 0x000002150A9985C0>], keywords=[])
Name(id='len', ctx=Load())
Load()
Name(id='clientConnections', ctx=Load())
Load()
Add()
Num(n=1)
Expr(value=Call(func=Attribute(value=Name(id='connect', ctx=Load()), attr='sendto', ctx=Load()), args=[<_ast.Call object at 0x000002150A998710>, <_ast.Name object at 0x000002150A9987F0>], keywords=[]))
Call(func=Attribute(value=Name(id='connect', ctx=Load()), attr='sendto', ctx=Load()), args=[<_ast.Call object at 0x000002150A998710>, <_ast.Name object at 0x000002150A9987F0>], keywords=[])
Attribute(value=Name(id='connect', ctx=Load()), attr='sendto', ctx=Load())
Name(id='connect', ctx=Load())
Load()
Load()
Call(func=Name(id='bytes', ctx=Load()), args=[<_ast.Name object at 0x000002150A998780>, <_ast.Str object at 0x000002150A9987B8>], keywords=[])
Name(id='bytes', ctx=Load())
Load()
Name(id='welcomeMessage', ctx=Load())
Load()
Str(s='utf-8')
Name(id='addr', ctx=Load())
Load()
Expr(value=Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Call object at 0x000002150A9988D0>], keywords=[]))
Call(func=Name(id='BroadcastMessage', ctx=Load()), args=[<_ast.Call object at 0x000002150A9988D0>], keywords=[])
Name(id='BroadcastMessage', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='{} has joined the chat.\n'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A998978>], keywords=[])
Attribute(value=Str(s='{} has joined the chat.\n'), attr='format', ctx=Load())
Str(s='{} has joined the chat.\n')
Load()
Name(id='name', ctx=Load())
Load()
Expr(value=Call(func=Attribute(value=Name(id='clientConnections', ctx=Load()), attr='append', ctx=Load()), args=[<_ast.List object at 0x000002150A998A90>], keywords=[]))
Call(func=Attribute(value=Name(id='clientConnections', ctx=Load()), attr='append', ctx=Load()), args=[<_ast.List object at 0x000002150A998A90>], keywords=[])
Attribute(value=Name(id='clientConnections', ctx=Load()), attr='append', ctx=Load())
Name(id='clientConnections', ctx=Load())
Load()
Load()
List(elts=[<_ast.Name object at 0x000002150A998AC8>, <_ast.Name object at 0x000002150A998B00>, <_ast.Name object at 0x000002150A998B38>], ctx=Load())
Name(id='connect', ctx=Load())
Load()
Name(id='addr', ctx=Load())
Load()
Name(id='name', ctx=Load())
Load()
Load()
Assign(targets=[<_ast.Name object at 0x000002150A998BA8>], value=Call(func=Attribute(value=Name(id='threading', ctx=Load()), attr='Thread', ctx=Load()), args=[], keywords=[<_ast.keyword object at 0x000002150A998C88>, <_ast.keyword object at 0x000002150A998CF8>]))
Name(id='cliThread', ctx=Store())
Store()
Call(func=Attribute(value=Name(id='threading', ctx=Load()), attr='Thread', ctx=Load()), args=[], keywords=[<_ast.keyword object at 0x000002150A998C88>, <_ast.keyword object at 0x000002150A998CF8>])
Attribute(value=Name(id='threading', ctx=Load()), attr='Thread', ctx=Load())
Name(id='threading', ctx=Load())
Load()
Load()
keyword(arg='target', value=Name(id='ListenToClient', ctx=Load()))
Name(id='ListenToClient', ctx=Load())
Load()
keyword(arg='args', value=Tuple(elts=[<_ast.Subscript object at 0x000002150A998D68>, <_ast.Subscript object at 0x000002150A998F28>], ctx=Load()))
Tuple(elts=[<_ast.Subscript object at 0x000002150A998D68>, <_ast.Subscript object at 0x000002150A998F28>], ctx=Load())
Subscript(value=Subscript(value=Name(id='clientConnections', ctx=Load()), slice=Index(value=UnaryOp(op=USub(), operand=Num(n=1))), ctx=Load()), slice=Index(value=Num(n=0)), ctx=Load())
Subscript(value=Name(id='clientConnections', ctx=Load()), slice=Index(value=UnaryOp(op=USub(), operand=Num(n=1))), ctx=Load())
Name(id='clientConnections', ctx=Load())
Load()
Index(value=UnaryOp(op=USub(), operand=Num(n=1)))
UnaryOp(op=USub(), operand=Num(n=1))
USub()
Num(n=1)
Load()
Index(value=Num(n=0))
Num(n=0)
Load()
Subscript(value=Subscript(value=Name(id='clientConnections', ctx=Load()), slice=Index(value=UnaryOp(op=USub(), operand=Num(n=1))), ctx=Load()), slice=Index(value=Num(n=2)), ctx=Load())
Subscript(value=Name(id='clientConnections', ctx=Load()), slice=Index(value=UnaryOp(op=USub(), operand=Num(n=1))), ctx=Load())
Name(id='clientConnections', ctx=Load())
Load()
Index(value=UnaryOp(op=USub(), operand=Num(n=1)))
UnaryOp(op=USub(), operand=Num(n=1))
USub()
Num(n=1)
Load()
Index(value=Num(n=2))
Num(n=2)
Load()
Load()
Expr(value=Call(func=Attribute(value=Name(id='cliThread', ctx=Load()), attr='start', ctx=Load()), args=[], keywords=[]))
Call(func=Attribute(value=Name(id='cliThread', ctx=Load()), attr='start', ctx=Load()), args=[], keywords=[])
Attribute(value=Name(id='cliThread', ctx=Load()), attr='start', ctx=Load())
Name(id='cliThread', ctx=Load())
Load()
Load()
ExceptHandler(type=Name(id='Exception', ctx=Load()), name='ex', body=[<_ast.Expr object at 0x000002150A999278>, <_ast.Expr object at 0x000002150A999400>, <_ast.For object at 0x000002150A9994E0>])
Name(id='Exception', ctx=Load())
Load()
Expr(value=Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A999320>], keywords=[]))
Call(func=Name(id='print', ctx=Load()), args=[<_ast.Call object at 0x000002150A999320>], keywords=[])
Name(id='print', ctx=Load())
Load()
Call(func=Attribute(value=Str(s='Exception: {}'), attr='format', ctx=Load()), args=[<_ast.Name object at 0x000002150A9993C8>], keywords=[])
Attribute(value=Str(s='Exception: {}'), attr='format', ctx=Load())
Str(s='Exception: {}')
Load()
Name(id='ex', ctx=Load())
Load()
Expr(value=Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='close', ctx=Load()), args=[], keywords=[]))
Call(func=Attribute(value=Name(id='s', ctx=Load()), attr='close', ctx=Load()), args=[], keywords=[])
Attribute(value=Name(id='s', ctx=Load()), attr='close', ctx=Load())
Name(id='s', ctx=Load())
Load()
Load()
For(target=Name(id='sock', ctx=Store()), iter=Name(id='clientConnections', ctx=Load()), body=[<_ast.Expr object at 0x000002150A999588>], orelse=[])
Name(id='sock', ctx=Store())
Store()
Name(id='clientConnections', ctx=Load())
Load()
Expr(value=Call(func=Attribute(value=Attribute(value=Name(id='sock', ctx=Load()), attr='first', ctx=Load()), attr='close', ctx=Load()), args=[], keywords=[]))
Call(func=Attribute(value=Attribute(value=Name(id='sock', ctx=Load()), attr='first', ctx=Load()), attr='close', ctx=Load()), args=[], keywords=[])
Attribute(value=Attribute(value=Name(id='sock', ctx=Load()), attr='first', ctx=Load()), attr='close', ctx=Load())
Attribute(value=Name(id='sock', ctx=Load()), attr='first', ctx=Load())
Name(id='sock', ctx=Load())
Load()
Load()
Load()