Jupyter for SRE
Jupyter is a tool that came out of the data science community. In
science, being able to replicate experiments is of the utmost importance
-- so a tool where you can "show your work" is helpful. However, being
able to show your work -- have colleagues validate what you have done,
repeat … read more
Write Python like an expert
Ten tricks to level up your Python.
Trick 0 -- KISS
Experts know about the weird dark corners of Python --
but do not use them in production code.
The first tip is remembering that while
Python has some interesting corners,
they are best avoided in production code.
Make your code as …
Interesting text encodings (and the people who love them)
(Thanks to Tom Prince and Nelson Elhage for suggestions
Nowadays, almost all text will be encoded in UTF-8 --
for good reasons,
it is a well thought out encoding.
Some of it will be in Latin 1, AKA ISO-8859-1,
which is popular in the western world.
Less of it … read more
Exploration Driven Development
"It's ok to mess up your own room."
Sometime there is a problem where the design is obvious --
at least to you.
Maybe it's simple.
Maybe you've solved one like that many times.
In those cases,
just go ahead --
use Test-Driven-Development, lint your code as you're writing,
and push a … read more
(This is an adaptation of part of the talk Kurt Rose and I
gave at PyBay 2017)
An abstraction cascade is a common anti-pattern in legacy system.
It is useful to understand how to recognize it,
how it tends to come about,
how to fix it --
and most importantly,
what … read more
Brute Forcing AES
Thanks to Paul Kehrer for reviewing!
Any mistakes or oversights that are left are my responsibility.
AES's maximum key size is 256 bits
(there are also 128 and 192 bit versions available).
Is that enough?
Well, if there is a cryptographic flaw in AES
a way to recover … read more
Announcing NColony 17.9.0
I have released NColony 17.9.0,
available in a PyPI near you.
New this version:
- Python 3 support!
- You can ask to, explicitly, inherit environment variables from the monitoring process.
Thanks to Mark Williams for reviewing many pull requests.
SSH to EC2
(Thanks to Donald Stufft for reviewing this post,
and to Glyph Lefkowitz for inspiring much of it.)
(JP Calderone wrote a Twisted version of this approach.)
It is often the case that after creating an EC2 instance in AWS,
the next step is SSHing.
This might be because the machine … read more
Python as a DSL
This is a joint post by Mark Williams and Moshe Zadka.
You are probably reading it on one of our blogs --
feel free to look at the other blog.
We decided it would be fun to write a post together
and see how it turns out.
We definitely … read more