From 0365002509b9e03f97e0070fba6bd2275410bbd9 Mon Sep 17 00:00:00 2001 From: Matthias Dellweg Date: Thu, 5 Dec 2024 17:19:11 +0100 Subject: [PATCH] Squash migrations before 0.4 fixes #334 --- CHANGES/334.removal | 1 + ...squashed_0011_alter_gemcontent_platform.py | 141 ++++++++++++++++++ 2 files changed, 142 insertions(+) create mode 100644 CHANGES/334.removal create mode 100644 pulp_gem/app/migrations/0001_initial_squashed_0011_alter_gemcontent_platform.py diff --git a/CHANGES/334.removal b/CHANGES/334.removal new file mode 100644 index 00000000..10f81e7f --- /dev/null +++ b/CHANGES/334.removal @@ -0,0 +1 @@ +Squashed and rebased old migrations (before the 0.4 release) to prepare for pulpcore 3.70 compatibility. diff --git a/pulp_gem/app/migrations/0001_initial_squashed_0011_alter_gemcontent_platform.py b/pulp_gem/app/migrations/0001_initial_squashed_0011_alter_gemcontent_platform.py new file mode 100644 index 00000000..289d3623 --- /dev/null +++ b/pulp_gem/app/migrations/0001_initial_squashed_0011_alter_gemcontent_platform.py @@ -0,0 +1,141 @@ +# Generated by Django 4.2.16 on 2024-12-06 13:29 + +import django.contrib.postgres.fields.hstore +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + replaces = [ + ("gem", "0001_initial"), + ("gem", "0002_gemrepository"), + ("gem", "0003_move_data_to_new_master_distribution_model"), + ("gem", "0004_alter_gemcontent_content_ptr_and_more"), + ("gem", "0005_rename_gemcontent_shallowgemcontent"), + ("gem", "0006_gemremote_excludes_gemremote_includes_and_more"), + ("gem", "0007_DATA_fix_prerelease"), + ("gem", "0008_gemcontent_platform"), + ("gem", "0009_check_datarepair"), + ("gem", "0010_delete_shallowgemcontent"), + ("gem", "0011_alter_gemcontent_platform"), + ] + + dependencies = [ + ("core", "0106_alter_artifactdistribution_distribution_ptr_and_more"), + ] + + operations = [ + migrations.CreateModel( + name="GemDistribution", + fields=[ + ( + "distribution_ptr", + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to="core.distribution", + ), + ), + ], + options={ + "default_related_name": "%(app_label)s_%(model_name)s", + }, + bases=("core.distribution",), + ), + migrations.CreateModel( + name="GemRemote", + fields=[ + ( + "remote_ptr", + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to="core.remote", + ), + ), + ("excludes", django.contrib.postgres.fields.hstore.HStoreField(null=True)), + ("includes", django.contrib.postgres.fields.hstore.HStoreField(null=True)), + ("prereleases", models.BooleanField(default=False)), + ], + options={ + "default_related_name": "%(app_label)s_%(model_name)s", + }, + bases=("core.remote",), + ), + migrations.CreateModel( + name="GemPublication", + fields=[ + ( + "publication_ptr", + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to="core.publication", + ), + ), + ], + options={ + "default_related_name": "%(app_label)s_%(model_name)s", + }, + bases=("core.publication",), + ), + migrations.CreateModel( + name="GemContent", + fields=[ + ( + "content_ptr", + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to="core.content", + ), + ), + ("name", models.TextField()), + ("version", models.TextField()), + ("checksum", models.CharField(db_index=True, max_length=64)), + ("dependencies", django.contrib.postgres.fields.hstore.HStoreField(default=dict)), + ("required_ruby_version", models.TextField(null=True)), + ("required_rubygems_version", models.TextField(null=True)), + ("prerelease", models.BooleanField(default=False)), + ("platform", models.TextField()), + ], + options={ + "default_related_name": "%(app_label)s_%(model_name)s", + "unique_together": {("checksum",)}, + }, + bases=("core.content",), + ), + migrations.CreateModel( + name="GemRepository", + fields=[ + ( + "repository_ptr", + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to="core.repository", + ), + ), + ], + options={ + "default_related_name": "%(app_label)s_%(model_name)s", + }, + bases=("core.repository",), + ), + ]