Inside the Head of PyDanny

Hi, I'm Daniel Roy Greenfeld, and welcome to my blog. I write about Python, Django, and much more.

Tag: Cheatsheet

Implemementing Manual Schema with Django REST Framework

BitCoin and Two Scoops of Django!

This is what will hopefully be the first in a series of reference articles for using Core API libraries with Django REST Framework (DRF).

This is an extraction from an existing production view running Django 1.11/2.0 on Python 3.6. The original code did something else, but ...

Read more ...


Pretty Formatting JSON in the Django Admin

Recently I was writing code to interact with a third-party API. The API changes frequently, especially the data contained in responses. However, that data has to be saved and periodically needs to be audited. I wanted a data model flexible enough to handle these periodic changes without a lot of ...

Read more ...


How To Create Installable, Reusable Django Packages

image

name

: Django Package Ecosystem: cookiecutter-djangopackage

align

: center

alt

: Django Package Ecosystem: cookiecutter-djangopackage

target

: https://www.pydanny.com/how-to-create-installable-django-packages.html

What I mean by an \"installable Django package\": a reusable component that can be shared across Django projects, allowing us to combine our own efforts with others. Some examples include:

Read more ...


Python Decorator Cheatsheet

I can never remember the syntax for writing decorators. I always have to look it up. Worse, I always have to remember where to look to find references. Hence the reason for this article. I'll never lose this reference: It's on my laptop and the internet.

Each type ...

Read more ...


Content Copyright © 2012-2018 Daniel Greenfeld. Proudly harnessed by Mountain, powered by Flask, and rendered by Frozen Flask, all of which take great advantage of Python.