# Generated by Django 4.2.5 on 2023-10-09 15:35

import datetime
import uuid

import django.db.models.deletion
from django.db import migrations, models

import django_napse.utils.constants
import django_napse.utils.findable_class


class Migration(migrations.Migration):
    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name="Architecture",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="Bot",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "uuid",
                    models.UUIDField(default=uuid.uuid4, editable=False, unique=True),
                ),
                ("name", models.CharField(default="Bot", max_length=100)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                ("active", models.BooleanField(default=True)),
            ],
        ),
        migrations.CreateModel(
            name="BotConfig",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "uuid",
                    models.UUIDField(default=uuid.uuid4, editable=False, unique=True),
                ),
                ("immutable", models.BooleanField(default=False)),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="Cluster",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("share", models.FloatField()),
                ("breakpoint", models.FloatField()),
                ("autoscale", models.BooleanField()),
            ],
        ),
        migrations.CreateModel(
            name="Connection",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "bot",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="connections",
                        to="django_napse_core.bot",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Controller",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("pair", models.CharField(max_length=10)),
                ("base", models.CharField(max_length=10)),
                ("quote", models.CharField(max_length=10)),
                ("interval", models.CharField(max_length=10)),
                ("min_notional", models.FloatField(null=True)),
                ("min_trade", models.FloatField(null=True)),
                ("lot_size", models.IntegerField(null=True)),
                ("price", models.FloatField(null=True)),
                ("last_price_update", models.DateTimeField(null=True)),
                ("last_settings_update", models.DateTimeField(null=True)),
            ],
        ),
        migrations.CreateModel(
            name="Exchange",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("name", models.CharField(max_length=200, unique=True)),
                ("description", models.TextField()),
            ],
        ),
        migrations.CreateModel(
            name="ExchangeAccount",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "uuid",
                    models.UUIDField(default=uuid.uuid4, editable=False, unique=True),
                ),
                ("name", models.CharField(max_length=200, unique=True)),
                ("testing", models.BooleanField(default=True)),
                ("description", models.TextField()),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "exchange",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="accounts",
                        to="django_napse_core.exchange",
                    ),
                ),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="Modification",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "status",
                    models.CharField(
                        default=django_napse.utils.constants.MODIFICATION_STATUS["PENDING"],
                        max_length=15,
                    ),
                ),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                ("ignore_failed_order", models.BooleanField(default=False)),
                ("key", models.CharField(max_length=100)),
                ("value", models.CharField(max_length=100)),
                ("target_type", models.CharField(max_length=100)),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="Plugin",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("category", models.CharField(max_length=255)),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="Strategy",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "architecture",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="strategy",
                        to="django_napse_core.architecture",
                    ),
                ),
                (
                    "config",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="strategy",
                        to="django_napse_core.botconfig",
                    ),
                ),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="Wallet",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("title", models.CharField(default="Wallet", max_length=255)),
                ("locked", models.BooleanField(default=False)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
            ],
            bases=(models.Model, django_napse.utils.findable_class.FindableClass),
        ),
        migrations.CreateModel(
            name="ArchitectureModification",
            fields=[
                (
                    "modification_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.modification",
                    ),
                ),
            ],
            bases=("django_napse_core.modification",),
        ),
        migrations.CreateModel(
            name="DCABotConfig",
            fields=[
                (
                    "botconfig_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.botconfig",
                    ),
                ),
                ("setting_timeframe", models.DurationField()),
            ],
            bases=("django_napse_core.botconfig",),
        ),
        migrations.CreateModel(
            name="DCAStrategy",
            fields=[
                (
                    "strategy_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.strategy",
                    ),
                ),
                ("variable_last_buy_date", models.DateTimeField(blank=True, null=True)),
            ],
            bases=("django_napse_core.strategy",),
        ),
        migrations.CreateModel(
            name="EmptyBotConfig",
            fields=[
                (
                    "botconfig_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.botconfig",
                    ),
                ),
                ("setting_empty", models.BooleanField()),
            ],
            bases=("django_napse_core.botconfig",),
        ),
        migrations.CreateModel(
            name="EmptyStrategy",
            fields=[
                (
                    "strategy_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.strategy",
                    ),
                ),
            ],
            bases=("django_napse_core.strategy",),
        ),
        migrations.CreateModel(
            name="LBOPlugin",
            fields=[
                (
                    "plugin_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.plugin",
                    ),
                ),
            ],
            bases=("django_napse_core.plugin",),
        ),
        migrations.CreateModel(
            name="MBPPlugin",
            fields=[
                (
                    "plugin_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.plugin",
                    ),
                ),
            ],
            bases=("django_napse_core.plugin",),
        ),
        migrations.CreateModel(
            name="SBVPlugin",
            fields=[
                (
                    "plugin_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.plugin",
                    ),
                ),
            ],
            bases=("django_napse_core.plugin",),
        ),
        migrations.CreateModel(
            name="StrategyModification",
            fields=[
                (
                    "modification_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.modification",
                    ),
                ),
            ],
            bases=("django_napse_core.modification",),
        ),
        migrations.CreateModel(
            name="TurboDCABotConfig",
            fields=[
                (
                    "botconfig_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.botconfig",
                    ),
                ),
                ("setting_timeframe", models.DurationField()),
                ("setting_percentage", models.FloatField()),
            ],
            bases=("django_napse_core.botconfig",),
        ),
        migrations.CreateModel(
            name="TurboDCAStrategy",
            fields=[
                (
                    "strategy_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.strategy",
                    ),
                ),
                ("variable_last_buy_date", models.DateTimeField(blank=True, null=True)),
            ],
            bases=("django_napse_core.strategy",),
        ),
        migrations.CreateModel(
            name="Transaction",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("amount", models.FloatField()),
                ("ticker", models.CharField(max_length=10)),
                (
                    "transaction_type",
                    models.CharField(default="TRANSFER", max_length=20),
                ),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "from_wallet",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="transactions_from",
                        to="django_napse_core.wallet",
                    ),
                ),
                (
                    "to_wallet",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="transactions_to",
                        to="django_napse_core.wallet",
                    ),
                ),
            ],
        ),
        migrations.AddField(
            model_name="plugin",
            name="strategy",
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="plugins",
                to="django_napse_core.strategy",
            ),
        ),
        migrations.CreateModel(
            name="OrderBatch",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "status",
                    models.CharField(
                        default=django_napse.utils.constants.ORDER_STATUS["PENDING"],
                        max_length=15,
                    ),
                ),
                (
                    "controller",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="order_batches",
                        to="django_napse_core.controller",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Order",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("price", models.FloatField()),
                ("pair", models.CharField(max_length=10)),
                ("side", models.CharField(max_length=10)),
                ("completed", models.BooleanField(default=False)),
                ("asked_for_amount", models.FloatField()),
                ("asked_for_ticker", models.CharField(max_length=10)),
                ("debited_amount", models.FloatField(default=0)),
                ("batch_share", models.FloatField(default=0)),
                ("exit_base_amount", models.FloatField(default=0)),
                ("exit_quote_amount", models.FloatField(default=0)),
                ("fees", models.FloatField(default=0)),
                ("fee_ticker", models.CharField(blank=True, max_length=10)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "batch",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="orders",
                        to="django_napse_core.orderbatch",
                    ),
                ),
                (
                    "connection",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="orders",
                        to="django_napse_core.connection",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="NapseSpace",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("name", models.CharField(max_length=200)),
                (
                    "uuid",
                    models.UUIDField(default=uuid.uuid4, editable=False, unique=True),
                ),
                ("description", models.TextField()),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "exchange_account",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="spaces",
                        to="django_napse_core.exchangeaccount",
                    ),
                ),
            ],
            options={
                "unique_together": {("name", "exchange_account")},
            },
        ),
        migrations.AddField(
            model_name="modification",
            name="order",
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="modifications",
                to="django_napse_core.order",
            ),
        ),
        migrations.CreateModel(
            name="Link",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("importance", models.FloatField()),
                (
                    "bot",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="link",
                        to="django_napse_core.bot",
                    ),
                ),
                (
                    "cluster",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="links",
                        to="django_napse_core.cluster",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Fleet",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "uuid",
                    models.UUIDField(default=uuid.uuid4, editable=False, unique=True),
                ),
                ("name", models.CharField(default="Fleet", max_length=100)),
                ("running", models.BooleanField(default=False)),
                ("setup_finished", models.BooleanField(default=False)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "exchange_account",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        to="django_napse_core.exchangeaccount",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Debit",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("amount", models.FloatField()),
                ("ticker", models.CharField(max_length=10)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "wallet",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="debits",
                        to="django_napse_core.wallet",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Credit",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("amount", models.FloatField()),
                ("ticker", models.CharField(max_length=10)),
                ("created_at", models.DateTimeField(auto_now_add=True)),
                (
                    "wallet",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="credits",
                        to="django_napse_core.wallet",
                    ),
                ),
            ],
        ),
        migrations.AddField(
            model_name="controller",
            name="exchange_account",
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="controller",
                to="django_napse_core.exchangeaccount",
            ),
        ),
        migrations.AddField(
            model_name="connection",
            name="owner",
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="connections",
                to="django_napse_core.wallet",
            ),
        ),
        migrations.AddField(
            model_name="cluster",
            name="fleet",
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="clusters",
                to="django_napse_core.fleet",
            ),
        ),
        migrations.AddField(
            model_name="cluster",
            name="template_bot",
            field=models.OneToOneField(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="cluster",
                to="django_napse_core.bot",
            ),
        ),
        migrations.AddField(
            model_name="botconfig",
            name="space",
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="bot_configs",
                to="django_napse_core.napsespace",
            ),
        ),
        migrations.AddField(
            model_name="bot",
            name="strategy",
            field=models.OneToOneField(
                on_delete=django.db.models.deletion.CASCADE,
                related_name="bot",
                to="django_napse_core.strategy",
            ),
        ),
        migrations.CreateModel(
            name="SpaceWallet",
            fields=[
                (
                    "wallet_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.wallet",
                    ),
                ),
                (
                    "owner",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="wallet",
                        to="django_napse_core.napsespace",
                    ),
                ),
            ],
            bases=("django_napse_core.wallet",),
        ),
        migrations.CreateModel(
            name="SpaceSimulationWallet",
            fields=[
                (
                    "wallet_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.wallet",
                    ),
                ),
                (
                    "owner",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="simulation_wallet",
                        to="django_napse_core.napsespace",
                    ),
                ),
            ],
            bases=("django_napse_core.wallet",),
        ),
        migrations.CreateModel(
            name="SinglePairArchitecture",
            fields=[
                (
                    "architecture_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.architecture",
                    ),
                ),
                (
                    "variable_last_candle_date",
                    models.DateTimeField(
                        default=datetime.datetime(
                            1970,
                            1,
                            1,
                            0,
                            0,
                            tzinfo=datetime.timezone.utc,
                        ),
                    ),
                ),
                (
                    "controller",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="single_pair_architectures",
                        to="django_napse_core.controller",
                    ),
                ),
            ],
            bases=("django_napse_core.architecture",),
        ),
        migrations.CreateModel(
            name="OrderWallet",
            fields=[
                (
                    "wallet_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.wallet",
                    ),
                ),
                (
                    "owner",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="wallet",
                        to="django_napse_core.order",
                    ),
                ),
            ],
            bases=("django_napse_core.wallet",),
        ),
        migrations.CreateModel(
            name="Currency",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("mbp", models.FloatField()),
                ("ticker", models.CharField(max_length=10)),
                ("amount", models.FloatField(default=0)),
                (
                    "wallet",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="currencies",
                        to="django_napse_core.wallet",
                    ),
                ),
            ],
            options={
                "unique_together": {("wallet", "ticker")},
            },
        ),
        migrations.AlterUniqueTogether(
            name="controller",
            unique_together={("pair", "interval", "exchange_account")},
        ),
        migrations.CreateModel(
            name="ConnectionWallet",
            fields=[
                (
                    "wallet_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.wallet",
                    ),
                ),
                (
                    "owner",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="wallet",
                        to="django_napse_core.connection",
                    ),
                ),
            ],
            bases=("django_napse_core.wallet",),
        ),
        migrations.CreateModel(
            name="ConnectionSpecificArgs",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("key", models.CharField(max_length=100)),
                ("value", models.CharField(default="None", max_length=100)),
                ("target_type", models.CharField(default="None", max_length=100)),
                (
                    "connection",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="specific_args",
                        to="django_napse_core.connection",
                    ),
                ),
            ],
            options={
                "unique_together": {("connection", "key")},
            },
        ),
        migrations.CreateModel(
            name="ConnectionModification",
            fields=[
                (
                    "modification_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.modification",
                    ),
                ),
                (
                    "connection_specific_arg",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="modifications",
                        to="django_napse_core.connectionspecificargs",
                    ),
                ),
            ],
            bases=("django_napse_core.modification",),
        ),
        migrations.AlterUniqueTogether(
            name="connection",
            unique_together={("owner", "bot")},
        ),
        migrations.CreateModel(
            name="BinanceAccount",
            fields=[
                (
                    "exchangeaccount_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="django_napse_core.exchangeaccount",
                    ),
                ),
                ("public_key", models.CharField(max_length=200)),
                ("private_key", models.CharField(max_length=200)),
            ],
            options={
                "unique_together": {("public_key", "private_key")},
            },
            bases=("django_napse_core.exchangeaccount",),
        ),
    ]
