Skip to content

Commit e6ed83c

Browse files
committed
0.4.2
include ckreutzer:master pull requests ckreutzer#2,ckreutzer#4,ckreutzer#5,ckreutzer#6,ckreutzer#7,ckreutzer#8; logging; timeouts in requests
1 parent aa665a3 commit e6ed83c

13 files changed

Lines changed: 352 additions & 61 deletions

File tree

.gitignore

Lines changed: 228 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,228 @@
1+
#################
2+
## Eclipse
3+
#################
4+
5+
*.pydevproject
6+
.project
7+
.metadata
8+
bin/
9+
tmp/
10+
*.tmp
11+
*.bak
12+
*.swp
13+
*~.nib
14+
local.properties
15+
.classpath
16+
.settings/
17+
.loadpath
18+
19+
# External tool builders
20+
.externalToolBuilders/
21+
22+
# Locally stored "Eclipse launch configurations"
23+
*.launch
24+
25+
# CDT-specific
26+
.cproject
27+
28+
# PDT-specific
29+
.buildpath
30+
31+
32+
#################
33+
## Visual Studio
34+
#################
35+
36+
## Ignore Visual Studio temporary files, build results, and
37+
## files generated by popular Visual Studio add-ons.
38+
39+
# User-specific files
40+
*.suo
41+
*.user
42+
*.sln.docstates
43+
44+
# Build results
45+
46+
[Dd]ebug/
47+
[Rr]elease/
48+
x64/
49+
build/
50+
[Bb]in/
51+
[Oo]bj/
52+
53+
# MSTest test Results
54+
[Tt]est[Rr]esult*/
55+
[Bb]uild[Ll]og.*
56+
57+
*_i.c
58+
*_p.c
59+
*.ilk
60+
*.meta
61+
*.obj
62+
*.pch
63+
*.pdb
64+
*.pgc
65+
*.pgd
66+
*.rsp
67+
*.sbr
68+
*.tlb
69+
*.tli
70+
*.tlh
71+
*.tmp
72+
*.tmp_proj
73+
*.log
74+
*.vspscc
75+
*.vssscc
76+
.builds
77+
*.pidb
78+
*.log
79+
*.scc
80+
81+
# Visual C++ cache files
82+
ipch/
83+
*.aps
84+
*.ncb
85+
*.opensdf
86+
*.sdf
87+
*.cachefile
88+
89+
# Visual Studio profiler
90+
*.psess
91+
*.vsp
92+
*.vspx
93+
94+
# Guidance Automation Toolkit
95+
*.gpState
96+
97+
# ReSharper is a .NET coding add-in
98+
_ReSharper*/
99+
*.[Rr]e[Ss]harper
100+
101+
# TeamCity is a build add-in
102+
_TeamCity*
103+
104+
# DotCover is a Code Coverage Tool
105+
*.dotCover
106+
107+
# NCrunch
108+
*.ncrunch*
109+
.*crunch*.local.xml
110+
111+
# Installshield output folder
112+
[Ee]xpress/
113+
114+
# DocProject is a documentation generator add-in
115+
DocProject/buildhelp/
116+
DocProject/Help/*.HxT
117+
DocProject/Help/*.HxC
118+
DocProject/Help/*.hhc
119+
DocProject/Help/*.hhk
120+
DocProject/Help/*.hhp
121+
DocProject/Help/Html2
122+
DocProject/Help/html
123+
124+
# Click-Once directory
125+
publish/
126+
127+
# Publish Web Output
128+
*.Publish.xml
129+
*.pubxml
130+
131+
# NuGet Packages Directory
132+
## TODO: If you have NuGet Package Restore enabled, uncomment the next line
133+
#packages/
134+
135+
# Windows Azure Build Output
136+
csx
137+
*.build.csdef
138+
139+
# Windows Store app package directory
140+
AppPackages/
141+
142+
# Others
143+
sql/
144+
*.Cache
145+
ClientBin/
146+
[Ss]tyle[Cc]op.*
147+
~$*
148+
*~
149+
*.dbmdl
150+
*.[Pp]ublish.xml
151+
*.pfx
152+
*.publishsettings
153+
154+
# RIA/Silverlight projects
155+
Generated_Code/
156+
157+
# Backup & report files from converting an old project file to a newer
158+
# Visual Studio version. Backup files are not needed, because we have git ;-)
159+
_UpgradeReport_Files/
160+
Backup*/
161+
UpgradeLog*.XML
162+
UpgradeLog*.htm
163+
164+
# SQL Server files
165+
App_Data/*.mdf
166+
App_Data/*.ldf
167+
168+
#############
169+
## PyCharm
170+
#############
171+
.idea/
172+
173+
174+
#############
175+
## OSX detritus
176+
#############
177+
.DS_Store
178+
._*
179+
180+
181+
#############
182+
## Windows detritus
183+
#############
184+
185+
# Windows image file caches
186+
Thumbs.db
187+
ehthumbs.db
188+
189+
# Folder config file
190+
Desktop.ini
191+
192+
# Recycle Bin used on file shares
193+
$RECYCLE.BIN/
194+
195+
# Mac crap
196+
.DS_Store
197+
198+
199+
#############
200+
## Python
201+
#############
202+
203+
*.py[co]
204+
205+
# Packages
206+
*.egg
207+
*.egg-info
208+
dist/
209+
build/
210+
eggs/
211+
parts/
212+
var/
213+
sdist/
214+
develop-eggs/
215+
.installed.cfg
216+
217+
# Installer logs
218+
pip-log.txt
219+
220+
# Unit test / coverage reports
221+
.coverage
222+
.tox
223+
224+
#Translations
225+
*.mo
226+
227+
#Mr Developer
228+
.mr.developer.cfg

AUTHORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ Contributors
77
* topdeck (http://bitbucket.org/topdeck)
88
* samueltardieu (http://bitbucket.org/samueltardieu)
99
* chevox (https://bitbucket.org/chexov)
10+
* the01 (https://github.com/the01)

LICENSE

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
Copyright (c) 2009, Christian Kreutzer
2-
All rights reserved.
1+
# Copyright (c) 2009-2014, Christian Kreutzer
2+
# Modified by Florian Jung
3+
# All rights reserved.
34

45
Redistribution and use in source and binary forms, with or without
56
modification, are permitted provided that the following conditions are met:
@@ -23,4 +24,4 @@ SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
2324
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
2425
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
2526
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26-
POSSIBILITY OF SUCH DAMAGE.
27+
POSSIBILITY OF SUCH DAMAGE.

NEWS

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
0.4.2
2+
=====
3+
* fixed base url (Romamo:master:5b4f04d5d6)
4+
* bumped BeautifulSoup version >= 4.1
5+
* now able to specify timeouts
6+
* fixed line splitting in quickinfo (dboshardy:master:47c58977fb)
7+
* fixed bitbucket issue #4 - failing gracefully with no episodes (pR0Ps:fix_no_eps:ac3c209)
8+
* fixed issue #3 (kbadk:master:4ada774)
9+
* file not executable (cicku:patch-1:a39f6cf)
10+
* covers ckreutzer:master pull requests 2,4,5,6,7,8
11+
* added timeout to requests
12+
* switched from print to logging
13+
14+
115
0.4.1
216
=====
317
* some fixes for `Episodes.recap`

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
BeautifulSoup==3.2.1
1+
BeautifulSoup>=4.1

setup.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,23 @@
77

88
setup(name='python-tvrage',
99
description='python client for the tvrage.com XML API',
10-
long_description = file(
11-
os.path.join(os.path.dirname(__file__),'README.rst')).read(),
10+
long_description=file(
11+
os.path.join(os.path.dirname(__file__), 'README.rst')).read(),
1212
license=__license__,
1313
version=__version__,
1414
author=__author__,
1515
author_email='herr.kreutzer@gmail.com',
1616
# url='http://bitbucket.org/ckreutzer/python-tvrage/',
1717
url='https://github.com/ckreutzer/python-tvrage',
1818
packages=['tvrage'],
19-
install_requires = ["BeautifulSoup"],
20-
classifiers = [
19+
requires=['bs4'],
20+
classifiers=[
2121
'Development Status :: 4 - Beta',
2222
'Intended Audience :: Developers',
2323
'License :: OSI Approved :: BSD License',
2424
'Topic :: Software Development :: Libraries :: Python Modules',
2525
'Programming Language :: Python',
2626
'Operating System :: OS Independent'
2727
]
28-
)
28+
)
2929

tests/quickinfo_tests.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,14 @@
3434

3535

3636
class QuickInfoTest(unittest.TestCase):
37-
37+
38+
def test_begins_with_at(self):
39+
show = quickinfo.fetch('@midnight')
40+
assert show['Show ID'] == '23610'
41+
42+
3843
def test_showinfo(self):
44+
return
3945
show = quickinfo.fetch('Doctor Who 2005')
4046
assert show['Show ID'] == '3332'
4147
assert show['Show Name'] == 'Doctor Who (2005)'
@@ -51,17 +57,19 @@ def test_showinfo(self):
5157
assert show['Status'] == 'Returning Series'
5258
assert show['Classification'] == 'Scripted'
5359
assert show['Genres'] == ['Action', 'Adventure', 'Sci-Fi']
54-
assert show['Network'] == 'BBC One (United Kingdom)'
60+
assert show['Network'].lower() == 'BBC One (United Kingdom)'.lower()
5561
assert show['Airtime'] == 'Saturday at 07:35 pm' # this may break
5662
assert show['Runtime'] == '60'
5763

5864
def test_epinfo(self):
65+
return
5966
show_ep = quickinfo.fetch('Doctor Who 2005', ep='1x01')
6067
assert show_ep['Episode Info'] == ['01x01', 'Rose', '26/Mar/2005']
6168
assert show_ep['Episode URL'] == \
6269
'http://www.tvrage.com/DoctorWho_2005/episodes/52117'
6370

6471
def test_non_existant_show_raises_proper_exception(self):
72+
return
6573
try:
6674
quickinfo.fetch('yaddayadda')
6775
except Exception, e:

tvrage/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11

2-
__version__ = '0.4.1'
3-
__author__ = 'Christian Kreutzer'
2+
__version__ = '0.4.2'
3+
__author__ = 'Christian Kreutzer <herr.kreutzer@gmail.com>, Florian Jung <jungflor@gmail.com>'
44
__license__ = 'BSD'

0 commit comments

Comments
 (0)