<commit_before>from django.contrib import admin
from django.core.urlresolvers import reverse

from positions import settings
from positions.models import Position, PositionContent

class PositionAdmin(admin.ModelAdmin):
    list_display = ('name', 'description', 'count', 
        'allow_all_types', 'change_content_order')
    search_fields = ('name', 'description')
    filter_horizontal = ('eligible_types',)

    def change_content_order(self, obj):
        return '<a href="%s">Change Order</a>' % reverse('positions_ordercontent', args=(str(obj.pk,)))
    change_content_order.short_description = ''
    change_content_order.allow_tags = True


class PositionContentAdmin(admin.ModelAdmin):
    list_display = ('position', 'content_object', 'order', 'add_date',)


admin.site.register(Position, PositionAdmin)
admin.site.register(PositionContent, PositionContentAdmin)<commit_msg>Fixed the fix that caused the error<commit_after>from django.contrib import admin
from django.core.urlresolvers import reverse

from positions import settings
from positions.models import Position, PositionContent

class PositionAdmin(admin.ModelAdmin):
    list_display = ('name', 'description', 'count', 
        'allow_all_types', 'change_content_order')
    search_fields = ('name', 'description')
    filter_horizontal = ('eligible_types',)

    def change_content_order(self, obj):
        return '<a href="%s">Change Order</a>' % reverse('positions_ordercontent', args=(str(obj.pk),))
    change_content_order.short_description = ''
    change_content_order.allow_tags = True


class PositionContentAdmin(admin.ModelAdmin):
    list_display = ('position', 'content_object', 'order', 'add_date',)


admin.site.register(Position, PositionAdmin)
admin.site.register(PositionContent, PositionContentAdmin)
{'fraction_non_alphanumeric': 0.11817168338907469, 'fraction_numerical': 0.0, 'mean_word_length': 5.93050193050193, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3348658', 'n_tokens_mistral': 501, 'n_tokens_neox': 487, 'n_words': 111}