chore: Remove python2 compatibility code

This commit is contained in:
Charles Marttinen 2018-10-18 19:28:47 -04:00 committed by Charles Marttinen
parent 4a3637fddb
commit 8832c819e3
12 changed files with 2 additions and 194 deletions

View file

@ -1,6 +1,3 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.conf.urls import include, url
from pokemon_v2 import urls as pokemon_v2_urls

View file

@ -11,9 +11,6 @@
# wipe it and rewrite each row using the data found in data/v2/csv.
# support python3
from __future__ import print_function
import csv
import os
import os.path

View file

@ -1,168 +0,0 @@
from __future__ import unicode_literals
from django.contrib import admin
from .models import * # NOQA
admin.site.register(Ability)
admin.site.register(AbilityName)
admin.site.register(AbilityEffectText)
admin.site.register(AbilityFlavorText)
admin.site.register(AbilityChange)
admin.site.register(AbilityChangeEffectText)
admin.site.register(Berry)
admin.site.register(BerryFirmness)
admin.site.register(BerryFirmnessName)
admin.site.register(BerryFlavor)
admin.site.register(Characteristic)
admin.site.register(CharacteristicDescription)
admin.site.register(ContestCombo)
admin.site.register(ContestEffectEffectText)
admin.site.register(ContestEffectFlavorText)
admin.site.register(ContestEffect)
admin.site.register(ContestType)
admin.site.register(ContestTypeName)
admin.site.register(EggGroup)
admin.site.register(EggGroupName)
admin.site.register(EncounterCondition)
admin.site.register(EncounterConditionValue)
admin.site.register(EncounterConditionName)
admin.site.register(EncounterConditionValueName)
admin.site.register(EncounterConditionValueMap)
admin.site.register(EncounterMethod)
admin.site.register(EncounterMethodName)
admin.site.register(EncounterSlot)
admin.site.register(Encounter)
admin.site.register(EvolutionChain)
admin.site.register(EvolutionTrigger)
admin.site.register(EvolutionTriggerName)
admin.site.register(Experience)
admin.site.register(Gender)
admin.site.register(Generation)
admin.site.register(GenerationName)
admin.site.register(GrowthRate)
admin.site.register(GrowthRateDescription)
admin.site.register(ItemCategory)
admin.site.register(ItemCategoryName)
admin.site.register(ItemAttribute)
admin.site.register(ItemAttributeMap)
admin.site.register(ItemAttributeDescription)
admin.site.register(ItemFlavorText)
admin.site.register(ItemFlingEffect)
admin.site.register(ItemFlingEffectEffectText)
admin.site.register(ItemGameIndex)
admin.site.register(ItemName)
admin.site.register(ItemPocketName)
admin.site.register(ItemPocket)
admin.site.register(ItemEffectText)
admin.site.register(Item)
admin.site.register(Language)
admin.site.register(LanguageName)
admin.site.register(LocationAreaEncounterRate)
admin.site.register(LocationAreaName)
admin.site.register(LocationArea)
admin.site.register(LocationGameIndex)
admin.site.register(LocationName)
admin.site.register(Location)
admin.site.register(Machine)
admin.site.register(MoveBattleStyle)
admin.site.register(MoveBattleStyleName)
admin.site.register(MoveChange)
admin.site.register(MoveDamageClass)
admin.site.register(MoveDamageClassDescription)
admin.site.register(MoveEffectChange)
admin.site.register(MoveEffectChangeEffectText)
admin.site.register(MoveEffectEffectText)
admin.site.register(MoveEffect)
admin.site.register(MoveAttributeDescription)
admin.site.register(MoveAttributeMap)
admin.site.register(MoveAttributeName)
admin.site.register(MoveAttribute)
admin.site.register(MoveFlavorText)
admin.site.register(MoveLearnMethod)
admin.site.register(MoveLearnMethodName)
admin.site.register(MoveMeta)
admin.site.register(MoveMetaAilment)
admin.site.register(MoveMetaAilmentName)
admin.site.register(MoveMetaCategoryDescription)
admin.site.register(MoveMetaCategory)
admin.site.register(MoveMetaStatChange)
admin.site.register(MoveName)
admin.site.register(MoveTargetDescription)
admin.site.register(MoveTarget)
admin.site.register(Move)
admin.site.register(NatureBattleStylePreference)
admin.site.register(NatureName)
admin.site.register(NaturePokeathlonStat)
admin.site.register(Nature)
admin.site.register(PalParkArea)
admin.site.register(PalParkAreaName)
admin.site.register(PalPark)
admin.site.register(PokeathlonStatName)
admin.site.register(PokeathlonStat)
admin.site.register(Pokedex)
admin.site.register(PokedexVersionGroup)
admin.site.register(PokedexDescription)
admin.site.register(Pokemon)
admin.site.register(PokemonAbility)
admin.site.register(PokemonColor)
admin.site.register(PokemonColorName)
admin.site.register(PokemonDexNumber)
admin.site.register(PokemonEggGroup)
admin.site.register(PokemonEvolution)
admin.site.register(PokemonForm)
admin.site.register(PokemonFormName)
admin.site.register(PokemonFormGeneration)
admin.site.register(PokemonGameIndex)
admin.site.register(PokemonHabitat)
admin.site.register(PokemonHabitatName)
admin.site.register(PokemonItem)
admin.site.register(PokemonMove)
admin.site.register(PokemonShape)
admin.site.register(PokemonShapeName)
admin.site.register(PokemonSpecies)
admin.site.register(PokemonSpeciesName)
admin.site.register(PokemonSpeciesDescription)
admin.site.register(PokemonSpeciesFlavorText)
admin.site.register(PokemonStat)
admin.site.register(PokemonType)
admin.site.register(Region)
admin.site.register(RegionName)
admin.site.register(StatName)
admin.site.register(Stat)
admin.site.register(SuperContestEffect)
admin.site.register(SuperContestCombo)
admin.site.register(SuperContestEffectFlavorText)
admin.site.register(Type)
admin.site.register(TypeName)
admin.site.register(TypeGameIndex)
admin.site.register(TypeEfficacy)
admin.site.register(Version)
admin.site.register(VersionName)
admin.site.register(VersionGroup)
admin.site.register(VersionGroupMoveLearnMethod)
admin.site.register(VersionGroupRegion)

View file

@ -1,13 +1,12 @@
from __future__ import unicode_literals
from rest_framework import viewsets
from rest_framework.response import Response
from rest_framework.views import APIView
from django.shortcuts import get_object_or_404
from django.http import Http404
import re
from .models import * # NOQA
from .serializers import * # NOQA
import re
###########################

View file

@ -1,6 +1,3 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations

View file

@ -1,6 +1,3 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models

View file

@ -1,6 +1,3 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations

View file

@ -1,4 +1,3 @@
from __future__ import unicode_literals
from django.db import models
#####################

View file

@ -1,5 +1,3 @@
from __future__ import unicode_literals
from django.urls import reverse
from rest_framework import serializers
from collections import OrderedDict

View file

@ -1,4 +1,3 @@
from __future__ import unicode_literals
from django.test import TestCase
from pokemon_v2.models import * # NOQA

View file

@ -1,4 +1,3 @@
from __future__ import unicode_literals
from rest_framework import status
from rest_framework.test import APITestCase
from pokemon_v2.models import * # NOQA

View file

@ -1,6 +1,3 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.conf.urls import include, url
#####################################