Skip to content

Commit

Permalink
fixed migrations error
Browse files Browse the repository at this point in the history
  • Loading branch information
alimaktabi committed Aug 26, 2024
1 parent 0775b47 commit c42a1ff
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
11 changes: 0 additions & 11 deletions prizetap/migrations/0076_alter_constraint_name.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,6 @@ def create_prizetap_constraint(apps, schema_editor):
)


def create_tokentap_constraint(apps, schema_editor):
Constraint = apps.get_model("tokenTap", "Constraint")

Constraint.objects.create(
name="core.HasVerifiedCloudflareCaptcha",
description="HasVerifiedCloudflareCaptcha",
title="Passed Cloudflare Captcha",
type="VER",
)


class Migration(migrations.Migration):

Expand Down Expand Up @@ -95,6 +85,5 @@ class Migration(migrations.Migration):
unique=True,
),
),
migrations.RunPython(create_tokentap_constraint),
migrations.RunPython(create_prizetap_constraint),
]
13 changes: 13 additions & 0 deletions tokenTap/migrations/0062_alter_constraint_name.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,18 @@
from django.db import migrations, models



def create_tokentap_constraint(apps, schema_editor):
Constraint = apps.get_model("tokenTap", "Constraint")

Constraint.objects.create(
name="core.HasVerifiedCloudflareCaptcha",
description="HasVerifiedCloudflareCaptcha",
title="Passed Cloudflare Captcha",
type="VER",
)


class Migration(migrations.Migration):

dependencies = [
Expand All @@ -15,4 +27,5 @@ class Migration(migrations.Migration):
name='name',
field=models.CharField(choices=[('core.BrightIDMeetVerification', 'BrightIDMeetVerification'), ('core.BrightIDAuraVerification', 'BrightIDAuraVerification'), ('core.HasNFTVerification', 'HasNFTVerification'), ('core.HasTokenVerification', 'HasTokenVerification'), ('core.HasTokenTransferVerification', 'HasTokenTransferVerification'), ('core.AllowListVerification', 'AllowListVerification'), ('core.HasENSVerification', 'HasENSVerification'), ('core.HasLensProfile', 'HasLensProfile'), ('core.IsFollowingLensUser', 'IsFollowingLensUser'), ('core.BeFollowedByLensUser', 'BeFollowedByLensUser'), ('core.DidMirrorOnLensPublication', 'DidMirrorOnLensPublication'), ('core.DidCollectLensPublication', 'DidCollectLensPublication'), ('core.HasMinimumLensPost', 'HasMinimumLensPost'), ('core.HasMinimumLensFollower', 'HasMinimumLensFollower'), ('core.BeFollowedByFarcasterUser', 'BeFollowedByFarcasterUser'), ('core.HasMinimumFarcasterFollower', 'HasMinimumFarcasterFollower'), ('core.DidLikedFarcasterCast', 'DidLikedFarcasterCast'), ('core.DidRecastFarcasterCast', 'DidRecastFarcasterCast'), ('core.IsFollowingFarcasterUser', 'IsFollowingFarcasterUser'), ('core.HasFarcasterProfile', 'HasFarcasterProfile'), ('core.BeAttestedBy', 'BeAttestedBy'), ('core.Attest', 'Attest'), ('core.HasDonatedOnGitcoin', 'HasDonatedOnGitcoin'), ('core.HasMinimumHumanityScore', 'HasMinimumHumanityScore'), ('core.HasGitcoinPassportProfile', 'HasGitcoinPassportProfile'), ('core.IsFollowingFarcasterChannel', 'IsFollowingFarcasterChannel'), ('core.BridgeEthToArb', 'BridgeEthToArb'), ('core.IsFollowinTwitterUser', 'IsFollowinTwitterUser'), ('core.BeFollowedByTwitterUser', 'BeFollowedByTwitterUser'), ('core.DidRetweetTweet', 'DidRetweetTweet'), ('core.DidQuoteTweet', 'DidQuoteTweet'), ('core.HasMuonNode', 'HasMuonNode'), ('core.DelegateArb', 'DelegateArb'), ('core.DelegateOP', 'DelegateOP'), ('core.DidDelegateArbToAddress', 'DidDelegateArbToAddress'), ('core.DidDelegateOPToAddress', 'DidDelegateOPToAddress'), ('core.GLMStakingVerification', 'GLMStakingVerification'), ('core.IsFollowingTwitterBatch', 'IsFollowingTwitterBatch'), ('core.IsFollowingFarcasterBatch', 'IsFollowingFarcasterBatch'), ('core.HasVerifiedCloudflareCaptcha', 'HasVerifiedCloudflareCaptcha'), ('tokenTap.OncePerMonthVerification', 'OncePerMonthVerification'), ('tokenTap.OnceInALifeTimeVerification', 'OnceInALifeTimeVerification'), ('faucet.OptimismHasClaimedGasConstraint', 'OptimismHasClaimedGasConstraint')], max_length=255, unique=True),
),
migrations.RunPython(create_tokentap_constraint),
]

0 comments on commit c42a1ff

Please sign in to comment.