Skip to content

Instantly share code, notes, and snippets.

Tobias Kunze rixx

Block or report user

Report or block rixx

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
rixx /
Created Aug 2, 2017
Django Url Considerations
from django.db import models
from urlman import NamedUrls
class Event(models.Model):
code = models.CharField(max_length=20)
class urls(NamedUrls):
base = 'orga:event.list'
detail = 'orga:event.view', {'event': self.code}

Keybase proof

I hereby claim:

  • I am rixx on github.
  • I am rixx ( on keybase.
  • I have a public key ASDSgbthxeP9hBggbdd7FMbQjKNL5zCBJumGVUtGRwDsawo

To claim this, I am signing this object:

rixx /
Created Jun 18, 2018
Delivering static files on fixed URL in Django
import os
from django.http import Http404, FileResponse
def get_static(request, path, content_type):
path = os.path.join(settings.BASE_DIR, 'pretalx/static', path)
if not os.path.exists(path):
raise Http404()
return FileResponse(open(path, 'rb'), content_type=content_type)
import sqlite3
import sys
def usage():
print("Usage: <file> <linenos>")
print(" e.g. foo/ 14,15\n")
print(" or foo/ 14-27\n")
rixx /
Created Jun 25, 2019
Getting tickets from Django's trac and putting them into an SQLite database – results at
import json
import sqlite3
from datetime import datetime
import requests
View notify.cfg
token = secrettoken
url =
user = secretusertoken
app = secretapptoken
You can’t perform that action at this time.