def convert_auto_field(field):
    connection = router.db_for_write(field.model)
    if settings.DATABASES[connection]['ENGINE'] in ('django_mongodb_engine',):
        # Check if AutoField is string for django-non-rel support
        return models.TextField
    return models.IntegerField
Names not defined with a L{ValueConstant} instance cannot be looked up
dataset/ETHPy150Open treyhunner/django-simple-history/simple_history/models.py/convert_auto_field--crossover with--dataset/ETHPy150Open nlloyd/SubliminalCollaborator/libs/twisted/python/test/test_constants.py/ValuesTests.test_notLookupMissingByName