Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add script to generate README from json file #64

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 40 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Must-watch videos about Python
Inspired by [js-must-watch](https://github.com/bolshchikov/js-must-watch). Create pull requests to add more awesome links :-)

## 2009
* David Beazley: **Inside the Python GIL**
* David Beazley: **Inside the Python GIL** (Webcast)
* Video: [youtube](https://www.youtube.com/watch?v=ph374fJqFPE)
* [Misc resources](http://www.dabeaz.com/GIL/)

Expand All @@ -17,116 +17,118 @@ Inspired by [js-must-watch](https://github.com/bolshchikov/js-must-watch). Creat

## 2011
* Raymond Hettinger: **API Design: Lessons Learned** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2011/schedule/presentations/263/)
* [Presentation](https://us.pycon.org/2011/schedule/presentations/263/)
* Video: [youtube](http://www.youtube.com/watch?v=heJuQWNdwJI)/[pyvideo](http://pyvideo.org/video/366/pycon-2011--api-design--lessons-learned)

## 2012
* Brandon Rhodes: **Python Design Patterns 1** (PyCon US)
* Brandon Rhodes: **Python Design Patterns 1** (PyOhio)
* Video: [youtube](https://www.youtube.com/watch?v=Er5K_nR5lDQ)/[pyvideo](http://pyvideo.org/video/1369/python-design-patterns-1)
* [Slides](http://rhodesmill.org/brandon/slides/2012-07-pyohio/)
* Erik Rose: **Parsing Horrible Things with Python** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2012/schedule/presentation/468/)
* [Presentation](https://us.pycon.org/2012/schedule/presentation/468/)
* Video: [youtube](https://www.youtube.com/watch?v=tCUdeLIj4hE)/[pyvideo](http://pyvideo.org/video/708/parsing-horrible-things-with-python)
* Jack Diederich: **Stop Writing Classes** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2012/schedule/presentation/352/)
* [Presentation](https://us.pycon.org/2012/schedule/presentation/352/)
* Video: [youtube](https://www.youtube.com/watch?v=o9pEzgHorH0)/[pyvideo](http://pyvideo.org/video/880/stop-writing-classes)
* Ned Batchelder: **Pragmatic Unicode, or, How do I stop the pain?** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2012/schedule/presentation/141/)
* [Presentation](https://us.pycon.org/2012/schedule/presentation/141/)
* Video: [youtube](https://www.youtube.com/watch?v=sgHbC6udIqc)/[pyvideo](http://pyvideo.org/video/948/pragmatic-unicode-or-how-do-i-stop-the-pain)
* [Slides with text](http://nedbatchelder.com/text/unipain.html)/[Just the slides](http://nedbatchelder.com/text/unipain/unipain.html)
* Peter Inglesby: **Discovering Descriptors** (EuroPython)
* [EuroPython presentation](https://ep2013.europython.eu/conference/talks/discovering-descriptors)
* [Presentation](https://ep2013.europython.eu/conference/talks/discovering-descriptors)
* Video: [youtube](https://www.youtube.com/watch?v=D3-NZXHO5QI)
* [Code](https://github.com/inglesp/Discovering-Descriptors)
* Raymond Hettinger: **The Art of Subclassing** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2012/schedule/presentation/399/)
* [Presentation](https://us.pycon.org/2012/schedule/presentation/399/)
* Video: [youtube](https://www.youtube.com/watch?v=miGolgp9xq8)/[pyvideo](http://pyvideo.org/video/879/the-art-of-subclassing)
* David Schachter: **How to Speed up a Python Program 114,000 times** (SF Python Usergroup)
* [Presentation](https://us.pycon.org/2012/schedule/presentation/399/)
* [Slides](http://davidschachter.com/ds/SF_Python_Meetup_slides_public.pdf)
* [Presentation](http://www.meetup.com/sfpython/events/89669532/)
* Video: [youtube](https://www.youtube.com/watch?v=e08kOj2kISU)
* [Slides](http://davidschachter.com/ds/SF_Python_Meetup_slides_public.pdf)

## 2013
* David Beazley: **Python 3 Metaprogramming** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2013/schedule/presentation/7/)
* [Presentation](https://us.pycon.org/2013/schedule/presentation/7/)
* Video: [youtube](https://www.youtube.com/watch?v=sPiWg5jSoZI)/[pyvideo](http://pyvideo.org/video/1716/python-3-metaprogramming)
* [Misc resources](http://www.dabeaz.com/py3meta/)
* Jessica McKellar: **The Future of Python - A Choose Your Own Adventure**
* Video [youtube](https://www.youtube.com/watch?v=d1a4Jbjc-vU)/[pyvideo](http://pyvideo.org/video/2375/the-future-of-python-a-choose-your-own-adventur)
* [Code](www.dabeaz.com/py3meta/py3meta.zip)
* Jessica McKellar: **The Future of Python - A Choose Your Own Adventure** (Kiwi Pycon)
* Video: [youtube](https://www.youtube.com/watch?v=d1a4Jbjc-vU)/[pyvideo](http://pyvideo.org/video/2375/the-future-of-python-a-choose-your-own-adventur)
* [Slides](https://speakerdeck.com/nzpug/jessica-mckellar-the-future-of-python-a-choose-your-own-adventure-keynote)
* Kenneth Reitz: **Python for Humans** (PyCon US)
* Video: [youtube](http://www.youtube.com/watch?v=QpkHt1hDYTo)/[pyvideo](http://pyvideo.org/video/1785/python-for-humans-1)
* [Slides](https://speakerdeck.com/pyconslides/python-for-humans)
* [Code](https://github.com/kennethreitz/python-for-humans)
* Ned Batchelder: **Loop like a native: while, for, iterators, generators** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2013/schedule/presentation/76/)
* [Presentation](https://us.pycon.org/2013/schedule/presentation/76/)
* Video: [youtube](https://www.youtube.com/watch?v=EnSu9hHGq5o)/[pyvideo](http://pyvideo.org/video/1758/loop-like-a-native-while-for-iterators-genera)
* [Slides with text](http://nedbatchelder.com/text/iter.html)/[Just the slides](http://nedbatchelder.com/text/iter/iter.html)
* Raymond Hettinger: **Python's Class Development Toolkit** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2013/schedule/presentation/125/)
* [Presentation](https://us.pycon.org/2013/schedule/presentation/125/)
* Video: [youtube](https://www.youtube.com/watch?v=HTLu2DFOdTg)/[pyvideo](http://pyvideo.org/video/1779/pythons-class-development-toolkit)
* [Slides](https://speakerdeck.com/pyconslides/pythons-class-development-toolkit-by-raymond-hettinger)
* Raymond Hettinger: **Transforming Code into Beautiful, Idiomatic Python** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2013/schedule/presentation/126/)
* [Presentation](https://us.pycon.org/2013/schedule/presentation/126/)
* Video: [youtube](https://www.youtube.com/watch?v=OSGv2VnC0go)/[pyvideo](http://pyvideo.org/video/1780/transforming-code-into-beautiful-idiomatic-python)
* [Slides](https://speakerdeck.com/pyconslides/transforming-code-into-beautiful-idiomatic-python-by-raymond-hettinger-1)

## 2014
* Alex Gaynor: **Fast Python, Slow Python** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/197/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/197/)
* Video: [youtube](https://www.youtube.com/watch?v=7eeEf_rAJds)/[pyvideo](http://pyvideo.org/video/2627/fast-python-slow-python)
* [Slides](https://speakerdeck.com/pycon2014/fast-python-slow-python-by-alex-gaynor)
* A. Jesse Jiryu Davis: **What Is Async, How Does It Work, And When Should I Use It?** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/284/)
* Video: [youtube](https://www.youtube.com/watch?v=9WV7juNmyE8)/[pyvideo](http://pyvideo.org/video/2565/what-is-async-how-does-it-work-and-when-should)
* [Slides](https://speakerdeck.com/pycon2014/what-is-async-how-does-it-work-and-when-should-i-use-it-by-a-jesse-jiryu-davis)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/284/)
* Video: [youtube](https://www.youtube.com/watch?v=9WV7juNmyE8)/[pyvideo](http://pyvideo.org/video/2565/what-is-async-how-does-it-work-and-when-should)
* [Slides](https://speakerdeck.com/pycon2014/what-is-async-how-does-it-work-and-when-should-i-use-it-by-a-jesse-jiryu-davis)
* Benjamin Peterson: **Garbage Collection in Python** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/153/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/153/)
* Video: [youtube](https://www.youtube.com/watch?v=iHVs_HkjdmI)/[pyvideo](http://pyvideo.org/video/2633/garbage-collection-in-python)
* [Slides](https://speakerdeck.com/pycon2014/garbage-collection-in-python-by-benjamin-peterson)
* Brandon Rhodes: **All Your Ducks In A Row: Data Structures in the Standard Library and Beyond** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/211/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/211/)
* Video: [youtube](https://www.youtube.com/watch?v=fYlnfvKVDoM)/[pyvideo](http://pyvideo.org/video/2571/all-your-ducks-in-a-row-data-structures-in-the-s)
* [Slides](http://rhodesmill.org/brandon/slides/2014-04-pycon/data-structures/)
* Brandon Rhodes: **The Clean Architecture** (PyOhio)
* Video: [youtube](https://www.youtube.com/watch?v=DJtef410XaM)/[pyvideo](http://pyvideo.org/video/2840/the-clean-architecture-in-python)
* [Slides](http://rhodesmill.org/brandon/slides/2014-07-pyohio/clean-architecture/)
* Christine Spang: **Subprocess to FFI: Memory, Performance, and Why You Shouldn't Shell** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/190/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/190/)
* Video: [youtube](https://www.youtube.com/watch?v=YAO7PUZvVPw)/[pyvideo](http://pyvideo.org/video/2640/subprocess-to-ffi-memory-performance-and-why-y)
* [Slides](https://speakerdeck.com/pycon2014/subprocess-to-ffi-by-christine-spang)
* David Beazley: **Generators: The Final Frontier** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/70/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/70/)
* Video: [youtube](https://www.youtube.com/watch?v=5-qadlG7tWo)/[pyvideo](http://pyvideo.org/video/2575/generators-the-final-frontier)
* [Slides](http://fr.slideshare.net/dabeaz/generators-the-final-frontier)
* Erik Rose: **Designing Poetic APIs** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/207/)
* Video: [youtube](http://www.youtube.com/watch?v=JQYnFyG7A8c)/[pyvideo](http://pyvideo.org/video/2647/designing-poetic-apis)/[vod](http://vod.com.ng/en/video/JQYnFyG7A8c/Erik-Rose-Designing-Poetic-APIs-PyCon-2014)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/207/)
* Video: [vod](http://vod.com.ng/en/video/JQYnFyG7A8c/Erik-Rose-Designing-Poetic-APIs-PyCon-2014)/[youtube](http://www.youtube.com/watch?v=JQYnFyG7A8c)/[pyvideo](http://pyvideo.org/video/2647/designing-poetic-apis)
* [Slides](https://speakerdeck.com/pycon2014/designing-poetic-apis-by-erik-rose)
* Guido van Rossum: **Tulip: Async I/O for Python 3** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/284/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/284/)
* Video: [youtube](https://www.youtube.com/watch?v=1coLC-MUCJc)
* Mike Müller: **Faster Python Programs through Optimization** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/71/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/71/)
* Video: [youtube](https://www.youtube.com/watch?v=wNBJDpyRm8w)/[pyvideo](http://pyvideo.org/video/607/faster-python-programs-through-optimization)
* [Slides](http://fr.slideshare.net/PyData/faster-python-programs-through-optimization-mike-muller)
* Ned Batchelder: **Getting Started Testing** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2014/schedule/presentation/150/)
* [Presentation](https://us.pycon.org/2014/schedule/presentation/150/)
* Video: [youtube](https://www.youtube.com/watch?v=FxSsnHeWQBY)/[pyvideo](http://pyvideo.org/video/2674/getting-started-testing)
* [Slides](https://speakerdeck.com/pycon2014/getting-started-testing-by-ned-batchelder)
* S Anand: **Faster data processing in Python** (PyCon IN)
* [PyCon presentation](http://in.pycon.org/funnel/2014/165-faster-data-processing-in-python)
* [Presentation](http://in.pycon.org/funnel/2014/165-faster-data-processing-in-python)
* Video: [youtube](https://www.youtube.com/watch?v=ylBslijJexw)
* [iPython Notebook](http://nbviewer.ipython.org/github/sanand0/ipython-notebooks/blob/master/Faster%20Data%20Processing%20in%20Python.ipynb)
* [Code](http://nbviewer.ipython.org/github/sanand0/ipython-notebooks/blob/master/Faster%20Data%20Processing%20in%20Python.ipynb)

## 2015
* Raymond Hettinger: **Beyond PEP 8 -- Best practices for beautiful intelligible code** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2015/schedule/presentation/416/)
* Raymond Hettinger: **Beyond PEP 8 -- Best practices for beautiful intelligible code** (PyCon Montreal)
* [Presentation](https://us.pycon.org/2015/schedule/presentation/416/)
* Video: [youtube](https://www.youtube.com/watch?v=wf-BqAjZb8M)

* David Beazley: **Python Concurrency From the Ground Up: LIVE!** (PyCon US)
* David Beazley: **Python Concurrency From the Ground Up - Live** (PyCon Montreal)
* Video: [youtube](https://www.youtube.com/watch?v=MCs5OvhV9S4)

* Ned Batchelder: **Facts and Myths about Python names and values** (PyCon US)
* [PyCon presentation](https://us.pycon.org/2015/schedule/presentation/362/)
* Guido van Rossum: **Type Hints** (PyCon Montreal)
* Video: [youtube](https://www.youtube.com/watch?v=2wDvzy6Hgxg)
* Ned Batchelder: **Facts and Myths about Python names and values** (PyCon Montreal)
* [Presentation](https://us.pycon.org/2015/schedule/presentation/362/)
* Video: [youtube](https://www.youtube.com/watch?v=_AEJHKGk9ns)/[pyvideo](http://pyvideo.org/video/3466/facts-and-myths-about-python-names-and-values)
* [Slides and new article](http://nedbatchelder.com/text/names1.html)/[Original article](http://nedbatchelder.com/text/names.html)
49 changes: 49 additions & 0 deletions readme_generator.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
"""Script to generate the README.md file from the json file."""
# !PYTHONIOENCODING=UTF-8 python % > README_2.md
import json


def bold(string):
"""Add markup for bold to argument string."""
return "**{0}**".format(string)


def link(title, url):
"""Add markup for link to arguments title/url."""
return "[{0}]({1})".format(title, url)


def print_data(title, data):
"""Print data if provided."""
if data is not None:
print(' * {0}'.format(link(title, data)))


def generate_markup(json_file_path='videos.json'):
"""Generate markup for README.md using json_file_path."""
print("""Must-watch videos about Python
=============
Inspired by {0}. Create pull requests to add more awesome links :-)""".format(link('js-must-watch', 'https://github.com/bolshchikov/js-must-watch')))

with open(json_file_path) as json_file:
# Get the content
content = json.load(json_file)
# Group it by year
content_by_year = dict()
for elt in content:
content_by_year.setdefault(elt["year"], []).append(elt)
# And print it
for year, content in content_by_year.items():
print('\n## {0}'.format(year))
for elt in content:
print('* {0}: {1} ({2})'
.format(
elt["presenter"], bold(elt["title"]), elt["venue"]))
print_data("Presentation", elt.get("presentation"))
print(' * Video: ' + "/".join(
link(name, url) for name, url in elt["videos"].items()))
print_data("Slides", elt.get("slides"))
print_data("Code", elt.get("code"))

if __name__ == '__main__':
generate_markup()
14 changes: 7 additions & 7 deletions videos.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"venue": "PyCon US",
"slides": "http://www.dabeaz.com/GIL/",
"videos": {
"youtube": "https://www.youtube.com/watch?v=ph374fJqFPE",
"youtube": "http://www.youtube.com/watch?v=Obt-vMVdM8s",
"pyvideo": "http://pyvideo.org/video/353/pycon-2010--understanding-the-python-gil---82"
},
"tags": ["gil", "optimization", "performance"]
Expand Down Expand Up @@ -83,7 +83,7 @@
"tags": ["classes"]
},
{
"title": "Pragmatic Unicode or How do I stop the pain?",
"title": "Pragmatic Unicode, or, How do I stop the pain?",
"presenter": "Ned Batchelder",
"year": 2012,
"venue": "PyCon US",
Expand Down Expand Up @@ -282,7 +282,7 @@
"slides": "https://speakerdeck.com/pycon2014/subprocess-to-ffi-by-christine-spang",
"videos": {
"youtube": "https://www.youtube.com/watch?v=YAO7PUZvVPw",
"pyvideo": "http://pyvideo.org/video/2640/subprocess-to-ffi-memory-performance-and-why-y)"
"pyvideo": "http://pyvideo.org/video/2640/subprocess-to-ffi-memory-performance-and-why-y"
},
"tags": ["performance"]
},
Expand All @@ -305,7 +305,7 @@
"year": 2014,
"venue": "PyCon US",
"presentation": "https://us.pycon.org/2014/schedule/presentation/207/",
"slides": "https://speakerdeck.com/pycon2014/designing-poetic-apis-by-erik-ros",
"slides": "https://speakerdeck.com/pycon2014/designing-poetic-apis-by-erik-rose",
"videos": {
"youtube": "http://www.youtube.com/watch?v=JQYnFyG7A8c",
"pyvideo": "http://pyvideo.org/video/2647/designing-poetic-apis",
Expand Down Expand Up @@ -356,7 +356,7 @@
"year": 2014,
"venue": "PyCon IN",
"presentation": "http://in.pycon.org/funnel/2014/165-faster-data-processing-in-python",
"notebook": "http://nbviewer.ipython.org/github/sanand0/ipython-notebooks/blob/master/Faster%20Data%20Processing%20in%20Python.ipynb",
"code": "http://nbviewer.ipython.org/github/sanand0/ipython-notebooks/blob/master/Faster%20Data%20Processing%20in%20Python.ipynb",
"videos": {
"youtube": "https://www.youtube.com/watch?v=ylBslijJexw"
},
Expand Down Expand Up @@ -402,8 +402,8 @@
"slides": "http://nedbatchelder.com/text/names1.html",
"videos": {
"youtube": "https://www.youtube.com/watch?v=_AEJHKGk9ns",
"pyvideo": "http://pyvideo.org/video/3466/facts-and-myths-about-python-names-and-values",
"pyvideo": "http://pyvideo.org/video/3466/facts-and-myths-about-python-names-and-values"
},
"tags": ["novice", "core"],
"tags": ["novice", "core"]
}
]