annotate iviewget.py @ 5:f2e0787f52b8 default tip

Tidy up output to be clearer. - Don't bother the user with XML errors & lack of asset tags. - Print a header for the channel & series lists. - Inform the user how to navigate the menus.
author Daniel O'Connor <darius@dons.net.au>
date Fri, 21 Aug 2009 13:05:59 +0930
parents c4188feb8f26
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
1 #!/usr/bin/env python
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
2
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
3 import iview
2
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
4 import os.path
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
5 import re
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
6 import subprocess
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
7 import sys
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
8 import time
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
9
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
10 outpath = '.'
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
11 outext = 'flv16x9'
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
12 flvstreamerpath = '/home/darius/projects/flvstreamer/flvstreamer_x86'
2
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
13 flvpattern = re.compile("FLVStreamer v")
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
14
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
15 def listChannels(iview):
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
16 i = 1
5
f2e0787f52b8 Tidy up output to be clearer.
Daniel O'Connor <darius@dons.net.au>
parents: 4
diff changeset
17 print "===================== Channel List ====================="
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
18 print "Id %-30s %-35s" % ('Name', 'Description')
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
19 for c in iview.channels:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
20 print "%2d %-30s %-35s" % (i, c.name, c.descr)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
21 i += 1
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
22
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
23 def listSeries(chan):
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
24 i = 1
5
f2e0787f52b8 Tidy up output to be clearer.
Daniel O'Connor <darius@dons.net.au>
parents: 4
diff changeset
25 print "===================== Series List ====================="
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
26 for s in chan.series:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
27 if len(s.title) > 1:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
28 title = s.title[1]
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
29 else:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
30 title = s.title[0]
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
31 print "%3d %s" % (i, title)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
32 i += 1
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
33
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
34 def getInt(f):
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
35 ans = f.readline()
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
36 try:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
37 i = int(ans)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
38 except ValueError:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
39 return None
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
40
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
41 return i
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
42
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
43 def getSeries(iview, series, outfile = None):
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
44 cmd = [flvstreamerpath]
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
45
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
46 if outfile == None:
3
34471d354603 Use os.path.join to construct the output filename, hopefully more portable.
Daniel O'Connor <darius@dons.net.au>
parents: 2
diff changeset
47 outfile = os.path.join(outpath, series.asset.replace('/', '-') + '.' + outext)
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
48 cmd += iview.genFetchCmd(series, outfile)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
49 p = subprocess.Popen(cmd)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
50 while True:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
51 res = p.poll()
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
52 if res == None:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
53 time.sleep(0.1)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
54 else:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
55 return res
2
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
56
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
57 def checkFLVStreamer():
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
58 try:
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
59 s = subprocess.Popen(flvstreamerpath, stdout = subprocess.PIPE, stderr = subprocess.PIPE)
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
60 except OSError:
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
61 print "Couldn't execute FLVstreamer"
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
62 return False
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
63 while s.poll() != 1:
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
64 time.sleep(0.1)
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
65
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
66 out, err = s.communicate()
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
67 if flvpattern.match(err) == None:
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
68 print "Unrecognised output from FLVstreamer"
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
69 return False
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
70
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
71 return True
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
72
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
73 if __name__ == "__main__":
2
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
74 if not checkFLVStreamer():
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
75 sys.exit(1)
6edc508e0775 Try and run flvstreamer on init and exit if it fails.
Daniel O'Connor <darius@dons.net.au>
parents: 0
diff changeset
76
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
77 iview = iview.IView()
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
78 if iview.metered:
4
c4188feb8f26 Make the unmetered warning more strident.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
79 print
c4188feb8f26 Make the unmetered warning more strident.
Daniel O'Connor <darius@dons.net.au>
parents: 3
diff changeset
80 print "========== **WARNING** iview is metered **WARNING** =========="
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
81 print
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
82
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
83 slist = []
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
84 while True:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
85 chan = None
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
86 listChannels(iview)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
87 while True:
5
f2e0787f52b8 Tidy up output to be clearer.
Daniel O'Connor <darius@dons.net.au>
parents: 4
diff changeset
88 print "Please select a channel number (0 to start downloading): ",
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
89 i = getInt(sys.stdin)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
90 if i != None and i >= 0 and i <= len(iview.channels):
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
91 break
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
92 print "Invalid entry, try again"
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
93
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
94 if i == 0:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
95 break
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
96
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
97 cidx = i - 1
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
98 chan = iview.channels[cidx]
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
99 chan.getSeries()
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
100
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
101 listSeries(chan)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
102 while True:
5
f2e0787f52b8 Tidy up output to be clearer.
Daniel O'Connor <darius@dons.net.au>
parents: 4
diff changeset
103 print
f2e0787f52b8 Tidy up output to be clearer.
Daniel O'Connor <darius@dons.net.au>
parents: 4
diff changeset
104 print "Please select which series to download (space separated numbers)"
f2e0787f52b8 Tidy up output to be clearer.
Daniel O'Connor <darius@dons.net.au>
parents: 4
diff changeset
105 print " or 0 to exit to channel menu: ",
0
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
106 res = sys.stdin.readline()
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
107 for r in res.split():
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
108 try:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
109 i = int(r)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
110 except ValueError:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
111 i = None
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
112
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
113 if i != None and i >= 0 and i <= len(chan.series):
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
114 slist += [chan.series[i - 1]]
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
115
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
116 if len(slist) > 0 or i == 0:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
117 break
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
118 print "Invalid entry, try again"
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
119
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
120 if len(slist) == 0:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
121 print "Nothing to download"
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
122 sys.exit(0)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
123
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
124 print "Downloading %d items" % (len(slist))
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
125 for series in slist:
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
126 print "Fetching " + series.asset
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
127 res = getSeries(iview, series)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
128 print "Result is " + str(res)
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
129 # Re-auth or the server won't love us
fa7ca67af8c9 Initial commit of a python program to fetch iview streams using flvstreamer.
Daniel O'Connor <darius@dons.net.au>
parents:
diff changeset
130 iview.getAuth()