Talk:May Week

message: Isn't Trinity May Ball traditionally on a Monday? cmɢʟee୯ ͡° ̮د ͡° ੭ 11:03, 13 June 2013 (UTC)
replies: text: Trinity May Ball date is indeed wrong, could someone who knows how to work with wiki tables change this? 131.111.233.196 (talk) 20:41, 13 June 2013 (UTC)
replies: text:  Changed it.  — Preceding unsigned comment added by 131.111.233.196 (talk) 20:48, 13 June 2013 (UTC)
thread_title:  Trinity May Ball 

message: This revision was created using this script:
import itertools
from pprint import pprint
from collections import namedtuple
Day = namedtuple('Day', 'balls june_events garden_parties other')
def process_table(t):
	print('=' * 80)
	print()
	t = iter(t)
	next(t)
	yield '{| class="wikitable" style="width: 100%; table-layout: fixed"\n'
	for line in t:
		if line.startswith('! '):
			headings = [heading.strip() for heading in line[2:].split('||')]
			break
	rows = [
		[event.strip() for event in line[2:].split('||')]
		for line in t
		if not line.startswith('|-')
	]
	pprint(rows)
	days = itertools.zip_longest(*rows)
	days = [[event for event in col if event] for col in days]
	grouped_days = []
	for day in days:
		day = set(day)
		balls = {e for e in day if 'ball' in e.lower()}
		day -= balls
		june_events = {e for e in day if 'june' in e.lower()}
		day -= june_events
		garden_parties = {e for e in day if 'garden' in e.lower()}
		day -= garden_parties
		other = day
		grouped_days.append(Day(balls, june_events, garden_parties, other))
	pprint(grouped_days)
	yield '! !! May balls !! June events !! Garden parties !! Other events\n'
	for h, d in zip(headings, grouped_days):
		yield '|-\n'
		yield '\n\n'
		yield '! scope="row" | ' + h + '\n'
		yield '| \n'
		yield '\n'.join(x + '\n' for x in sorted(d.balls))
		yield '| \n'
		yield '\n'.join(x + '\n' for x in sorted(d.june_events))
		yield '| \n'
		yield '\n'.join(x + '\n' for x in sorted(d.garden_parties))
		yield '| \n'
		yield '\n'.join(x + '\n' for x in sorted(d.other))
	yield '|}'
	# return.join(reversed(t))
with open('mayweek.txt') as f, open('mayweek.new.txt', 'w') as out:
	table = []
	for line in f:
		if line.startswith('{|') or table:
			table.append(line)
		if line.startswith('|}'):
			line = .join(process_table(table))
			table = []
		if not table:
			out.write(line)
Eric Wieser (talk) 16:32, 24 March 2014 (UTC)
thread_title:  Script used 

message: Hello fellow Wikipedians,
I have just modified 12 external links on May Week. Please take a moment to review my edit. If you have any questions, or need the bot to ignore the links, or the page altogether, please visit this simple FaQ for additional information. I made the following changes:
*Added archive https://web.archive.org/web/20110625222206/http://www.cus.org/ to http://www.cus.org/
*Added archive https://web.archive.org/web/20140516195710/http://hugheshallmayball.org.uk/ to http://www.hugheshallmayball.org.uk/
*Added archive https://web.archive.org/web/20110625222206/http://www.cus.org/ to http://www.cus.org/
*Added  tag to http://www.stjohnsmayball.com/
*Added archive https://web.archive.org/web/20120218141834/http://www.peterhousemayball.com/ to http://www.peterhousemayball.com/
*Added  tag to http://www.stjohnsmayball.com/
*Added  tag to http://www.stjohnsmayball.com/
*Added archive https://web.archive.org/web/20110622025340/http://www.clarehalljuneevent.co.uk/ to http://www.clarehalljuneevent.co.uk/
*Added  tag to http://www.stjohnsmayball.com/
*Added  tag to http://www.catzmayball2010.com/
*Added archive https://web.archive.org/web/20100820233319/http://www.homertonjuneevent.co.uk/ to http://www.homertonjuneevent.co.uk/
*Added archive https://web.archive.org/web/20070814181038/http://www.hughesmayball.com/ to http://www.hughesmayball.com/
*Added archive https://web.archive.org/web/20120218141834/http://www.peterhousemayball.com/ to http://www.peterhousemayball.com/
*Added  tag to http://www.stjohnsmayball.com/
*Added archive https://web.archive.org/web/20070216032644/http://www.thjuneevent.com/ to http://www.thjuneevent.com/
*Added archive https://web.archive.org/web/20070814181038/http://www.hughesmayball.com/ to http://www.hughesmayball.com/
*Added archive https://web.archive.org/web/20051216002620/http://caiusmayball.com/ to http://www.caiusmayball.com/
*Added  tag to http://www.stjohnsmayball.com/
*Added archive https://web.archive.org/web/20070216032644/http://www.thjuneevent.com/ to http://www.thjuneevent.com/
When you have finished reviewing my changes, you may follow the instructions on the template below to fix any issues with the URLs.
Cheers.—InternetArchiveBot (Report bug) 02:33, 23 January 2018 (UTC)
thread_title:  External links modified (January 2018)