Merge lp:~slimey/engage/bugfix into lp:engage

Proposed by Simon C
Status: Merged
Approved by: Simon C
Approved revision: no longer in the source branch.
Merged at revision: 6
Proposed branch: lp:~slimey/engage/bugfix
Merge into: lp:engage
Diff against target: 129 lines (+24/-9)
7 files modified
debian/changelog (+6/-0)
debian/control (+1/-1)
src/engage/media/movie.py (+3/-1)
src/engage/media/static.py (+1/-0)
src/engage/ui/carousel.py (+0/-1)
src/engage/ui/web.py (+2/-2)
src/engage/util/atv.py (+11/-4)
To merge this branch: bzr merge lp:~slimey/engage/bugfix
Reviewer Review Type Date Requested Status
Simon C Approve
Review via email: mp+127493@code.launchpad.net

Commit message

Merge fix to Depends line for lucid builds

Description of the change

Fixes launchpad build issue

To post a comment you must log in.
Revision history for this message
Simon C (slimey) :
review: Approve
lp:~slimey/engage/bugfix updated
6. By Simon C

Merge fix to Depends line for lucid builds

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2012-09-25 17:47:25 +0000
3+++ debian/changelog 2012-10-02 14:05:27 +0000
4@@ -1,3 +1,9 @@
5+engage (0.6.3) precise; urgency=low
6+
7+ * Bugfix for launchpad build and movie playing
8+
9+ -- Simon C <simonc@ensoft.co.uk> Tue, 02 Oct 2012 13:19:15 +0100
10+
11 engage (0.6.2) precise; urgency=low
12
13 * Packaging improvement
14
15=== modified file 'debian/control'
16--- debian/control 2012-09-25 12:44:16 +0000
17+++ debian/control 2012-10-02 14:05:27 +0000
18@@ -8,7 +8,7 @@
19 Package: engage
20 Architecture: all
21 # snmp package is just for snmptranslate
22-Depends: python (>= ${python:Versions}), python-setuptools, python-zope.interface, python-rrdtool, libsnmp-python, python-pynetsnmp, snmp, snmp-mibs-downloader, ${python:Depends}, ${misc:Depends}
23+Depends: python, python-setuptools, python-zope.interface, python-rrdtool, libsnmp-python, python-pynetsnmp, snmp, snmp-mibs-downloader, ${misc:Depends}
24 Description: Combined system/network statistics and Apple TV control framework
25 EnGage is a plugin-based framework for gathering, summarizing, and displaying
26 system or network administration data.
27
28=== modified file 'src/engage/media/movie.py'
29--- src/engage/media/movie.py 2012-09-25 12:44:16 +0000
30+++ src/engage/media/movie.py 2012-10-02 14:05:27 +0000
31@@ -2,6 +2,7 @@
32 #
33 # Simon C, September 2012
34
35+import re
36 from twisted.python import log
37 from engage.media import MediaSource, StartMediaSource
38
39@@ -15,7 +16,8 @@
40 self.register_cb(self, 1)
41
42 def show(self):
43- d = self.atv.show_movie('http://172.22.22.143:8421/mp4/amy-janet.mp4')
44+ url = re.sub('\|', ':', self.cfg['url'])
45+ d = self.atv.show_movie(url)
46 return d
47
48 start = StartMediaSource('movie', MovieMediaSource)
49
50=== modified file 'src/engage/media/static.py'
51--- src/engage/media/static.py 2012-09-25 12:44:16 +0000
52+++ src/engage/media/static.py 2012-10-02 14:05:27 +0000
53@@ -30,6 +30,7 @@
54 def show(self):
55 item = random.randint(0, len(self.photos) - 1)
56 pathname = self.photos[item]
57+ log.msg("Showing static image %s" % pathname)
58 d = self.atv.show_photo(pathname)
59 return d
60
61
62=== modified file 'src/engage/ui/carousel.py'
63--- src/engage/ui/carousel.py 2012-09-25 12:44:16 +0000
64+++ src/engage/ui/carousel.py 2012-10-02 14:05:27 +0000
65@@ -83,7 +83,6 @@
66 failure.printTraceback()
67 d.addErrback(handle_failure)
68 def reset(result):
69- log.msg("FINAL CALLBACK!!!")
70 reactor.callLater(self.period, self.maybe_show_next_photo)
71 d.addBoth(reset)
72
73
74=== modified file 'src/engage/ui/web.py'
75--- src/engage/ui/web.py 2012-09-25 12:44:16 +0000
76+++ src/engage/ui/web.py 2012-10-02 14:05:27 +0000
77@@ -159,8 +159,8 @@
78 site.putChild("", Main(config))
79 site.putChild("graph", Graph(config))
80 site.putChild("png", File('%s/png' % web_config['web_static_dir']))
81- site.putChild("mp4", File('%s/mp4' % web_config['web_static_dir']))
82-
83+ if 'web_mp4_dir' in web_config:
84+ site.putChild("mp4", File(web_config['web_mp4_dir']))
85
86 web = Site(site)
87 tcp_service = internet.TCPServer(int(web_config['http_port']), web)
88
89=== modified file 'src/engage/util/atv.py'
90--- src/engage/util/atv.py 2012-09-25 12:44:16 +0000
91+++ src/engage/util/atv.py 2012-10-02 14:05:27 +0000
92@@ -11,7 +11,7 @@
93 from twisted.web.client import FileBodyProducer
94 from twisted.web.http_headers import Headers
95
96-POLL_INTERVAL = 1
97+POLL_INTERVAL = 2
98
99 class ResponseReceiver(Protocol):
100
101@@ -25,18 +25,25 @@
102 for key in ('position', 'duration')]
103 if duration > 0:
104 remaining = duration - position
105+ if remaining < 0:
106+ remaining = 0
107 if remaining < self.remaining:
108 self.remaining = remaining
109+ elif remaining > self.remaining * 2:
110+ self.remaining += remaining % self.remaining
111
112 log.msg("Video at %f/%f; timer reset to %f" %
113 (position, duration, self.remaining))
114
115 def connectionLost(self, reason):
116 if self.remaining < POLL_INTERVAL:
117- log.msg("Last %f seconds, just waiting" % self.remaining)
118+ log.msg("Video's final %f seconds, just waiting" % self.remaining)
119+ d = self.finished
120 else:
121- self.finished.addCallback(self.fire_again)
122- reactor.callLater(self.remaining, self.finished.callback, None)
123+ d = defer.Deferred()
124+ d.addCallback(self.fire_again)
125+ d.addCallback(self.finished.callback)
126+ reactor.callLater(self.remaining, d.callback, None)
127
128
129 class ATV(object):

Subscribers

People subscribed via source and target branches

to all changes: