talklib 2.1.1__tar.gz → 2.1.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.2
2
2
  Name: talklib
3
- Version: 2.1.1
3
+ Version: 2.1.2
4
4
  Summary: A package to automate processing of shows/segments airing on the TL
5
5
  Author-email: Ben Weddle <ben.weddle@gmail.com>
6
6
  Maintainer-email: Ben Weddle <ben.weddle@gmail.com>
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "talklib"
3
- version = "2.1.1"
3
+ version = "2.1.2"
4
4
  description = "A package to automate processing of shows/segments airing on the TL"
5
5
  readme = "README.md"
6
6
  license = {file = "LICENSE.txt"}
@@ -171,11 +171,13 @@ class Episode(BaseModel):
171
171
  return result
172
172
 
173
173
  def check_for_duplicate_episode(self, title: str):
174
+ self.notifications.prep_syslog(message="checking for duplicate episode...")
174
175
  if title == self.episode_title:
175
176
  self.cleanup_files_on_abort()
176
177
  to_send = "Found episode with identical title already in feed. Aborting..."
177
178
  self.notifications.send_notifications(message=to_send, subject="Error")
178
179
  raise Exception (to_send)
180
+ self.notifications.prep_syslog(message="no duplicate episode found")
179
181
  return
180
182
 
181
183
  def cleanup_files_on_abort(self):
@@ -194,7 +196,11 @@ class Episode(BaseModel):
194
196
  root = feed.getroot()
195
197
  root = root.find('channel')
196
198
 
197
- self.check_for_duplicate_episode(title=root.find("item").find("title").text)
199
+ # if we have a new feed, or a feed with no episodes
200
+ try:
201
+ self.check_for_duplicate_episode(title=root.find("item").find("title").text)
202
+ except:
203
+ pass
198
204
 
199
205
  self.notifications.prep_syslog(message="Building the new <item> element")
200
206
  item = ET.Element('item')
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.2
2
2
  Name: talklib
3
- Version: 2.1.1
3
+ Version: 2.1.2
4
4
  Summary: A package to automate processing of shows/segments airing on the TL
5
5
  Author-email: Ben Weddle <ben.weddle@gmail.com>
6
6
  Maintainer-email: Ben Weddle <ben.weddle@gmail.com>
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes