Skip to content

Commit

Permalink
remove approved field from chipy_v3
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlFK committed Apr 8, 2024
1 parent 3337790 commit 038bc3f
Showing 1 changed file with 21 additions and 8 deletions.
29 changes: 21 additions & 8 deletions dj/scripts/addeps.py
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,9 @@ def add_eps(self, schedule, show):
# veyepar, remote
a1,a2 = getattr(episode,f), row[f]

if self.options.verbose:
print(f"{f=}")

if f in ("emails", "reviewers"):
# don't always have rights to get email
if not a2:
Expand Down Expand Up @@ -1774,7 +1777,9 @@ def chipy_v3(self, schedule, show):

# import code; code.interact(local=locals())

schedule = [s for s in schedule if s['approved']]
# schedule = [s for s in schedule if s['status']]
# 'status': 'confirmed'
# schedule = [s for s in schedule if s['approved']]
# schedule = [s for s in schedule if s['start_time']]
print("we have start times?")
for s in schedule:
Expand All @@ -1790,6 +1795,7 @@ def chipy_v3(self, schedule, show):
('license','license'),
('start_time', 'start'),
('length', 'duration'),
('reviewers', 'reviewers'),
('', 'conf_url'),
('', 'tags'),
('', 'twitter_id'),
Expand Down Expand Up @@ -1825,6 +1831,8 @@ def chipy_v3(self, schedule, show):
[ a['email'] for a in event['emails']
if a['email'] ])

event['reviewers'] = ', '.join( event['reviewers'] )

# if not event['emails']: # no email found
# event['emails'] = "ChiPy <[email protected]>"

Expand All @@ -1833,8 +1841,6 @@ def chipy_v3(self, schedule, show):

event['conf_url'] = show.conf_url

event['reviewers'] = ""


rooms = set(row['location'] for row in events)
self.add_rooms(rooms,show)
Expand Down Expand Up @@ -5505,6 +5511,13 @@ def one_show(self, show):
response = session.get(url, params=payload, verify=False,
headers=headers)

if self.options.debug:
# save for later
filename=self.show_dir + "/schedule.txt"
open(filename,'w').write(response.content.decode())
# j=file(filename).read()


if self.options.client =='emwc':
# return self.emwc_wiki(show, response)
return self.emwc_sheet(show, response, session)
Expand Down Expand Up @@ -5554,13 +5567,13 @@ def one_show(self, show):
# (pyohio 2012)
# schedule = eval(j)

# save for later
# filename="schedule/%s_%s.json" % ( client.slug, show.slug )
# file(filename,'w').write(j)
# j=file(filename).read()

if self.options.verbose: pprint(schedule)

if self.options.debug:
# save for later
filename=self.show_dir + "/schedule.json"
json.dump(schedule, open(filename,'w'), indent=2)

# if self.options.verbose: print j[:40]
if self.options.keys: return self.dump_keys(schedule)

Expand Down

0 comments on commit 038bc3f

Please sign in to comment.