Episode #67: Result of moving Python to Github
Sponsored by DigitalOcean! http://do.co/python
Brian #1: Building a blog with Pelican
- We did cover Pelican in episode 38, but this is a nice tutorial in 7 parts on building a blog.
- Peter Kazarinoff, @pkazarinoff
- Nice blog with a focus on engineering students.
- Starts with installing Python and git and some other tools.
- Step by step, every action to get a a blog up as a static site hosted on github pages.
Michael #2: Notifiers
- Got an app or service and you want to enable your users to use notifications with their provider of choice?
- Working on a script and you want to receive notification based on its output?
- A one stop shop for all notification providers with a unified and simple interface.
- A unified interface means that you already support any new providers that will be added, no more work needed!
- Some providers
- Python 3 only
Brian #3: Using Makefiles in Python projects
- Krzysztof Żuraw, @krzysztof_zuraw
- Alerted to this article from kidpixo, @kidpixo
- We don’t usually think of Makefiles and Python together, but they can be a handy place to keep common scripts for a project all in one place.
- This article is a nice gentle intro to Makefiles and shows some cool uses:
- cleaning out .pyc files
- cleaning out egg directories
- running tests with flags
- starting a test server
- sorting import files
Michael #4: Result of moving Python to Github
- See the graph linked in the post
- A couple of quick numbers (including PRs too) from 2017 compared to 2016:
- the number of commit has increased by 190%
- inserted lines of code has increased by 140%
- number of unique contributors has increased by 1300%
- number of returning contributors has increased by 900%
- One comment was: “Personally, I would like them moving to Gitlab instead, but still good news.” I tend to disagree.
- Maurice Hayward, @maurice_hayward
- Inspired by some tweets by Stephanie Hurlburt, @sehurlburt
- Stop saying these words when describing yourself or your accomplishments. These words are now under BAN: "My project is..." - very small/basic/simple - not that good - a thing I wrote - just by a newbie - something I didn't spend a lot of time/effort on - silly - not that useful Just state the topic and let others be the judge.
- Really think about the value you bring, then let everybody know.
- Be Proud of Yourself!
Michael #6: 5 speed improvements in Python 3.7
- Calling methods faster (maybe)
- Python 3.7 adds 2 new Opcodes, LOAD_METHOD and CALL_METHOD for when the compiler sees x.method(...) it uses these new Opcodes.
- Bound methods with no arguments are now faster
- str.find() is faster for some characters
- Some unicode characters have an unfortunate issue when scanning a string for occurrences using str.find(x), seeing up to 25x slow down.
- These are still slower, but now 3x slower than ASCII characters instead of 25x!
- os.fwalk is 2x faster
- Regular expressions are faster
- A change was made in Python 3.6 which slowed down this call when flags were passed which were integers. Python 3.7 “fixes” the slowdown but is still not as fast as Python 3.5
- Regular expressions are faster for case-insensitive matching
- The speed improvement is significant, if you’re matching ASCII characters you can see up to a 20x improvements in matching time since it’s now doing a lookup instead of running lower() over each character.
Follow up and other news