Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore core migration 0005 #219

Merged
merged 1 commit into from
Dec 16, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
128 changes: 64 additions & 64 deletions core/migrations/0005_auto_20231203_0832.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,68 +11,68 @@ class Migration(migrations.Migration):
]

operations = [
migrations.RunSQL("""
INSERT INTO core_walletaccount (
id,
name,
private_key,
network_type
)
SELECT
id,
name,
private_key,
network_type
FROM
faucet_walletaccount;
INSERT INTO core_chain (
id,
chain_name,
symbol,
chain_id,
rpc_url,
decimals,
explorer_url,
logo_url,
native_currency_name,
poa,
rpc_url_private,
wallet_id,
modal_url,
max_gas_price,
gas_multiplier,
chain_type,
is_testnet,
is_active,
enough_fee_multiplier,
explorer_api_key,
explorer_api_url
)
SELECT
id,
chain_name,
symbol,
chain_id,
rpc_url,
decimals,
explorer_url,
logo_url,
native_currency_name,
poa,
rpc_url_private,
wallet_id,
modal_url,
max_gas_price,
gas_multiplier,
chain_type,
is_testnet,
is_active,
enough_fee_multiplier,
explorer_api_key,
explorer_api_url
FROM
faucet_chain;
SELECT setval(pg_get_serial_sequence('"core_walletaccount"','id'), coalesce(max("id"), 1), max("id") IS NOT null) FROM "core_walletaccount";
SELECT setval(pg_get_serial_sequence('"core_chain"','id'), coalesce(max("id"), 1), max("id") IS NOT null) FROM "core_chain";
""", reverse_sql="")
# migrations.RunSQL("""
# INSERT INTO core_walletaccount (
# id,
# name,
# private_key,
# network_type
# )
# SELECT
# id,
# name,
# private_key,
# network_type
# FROM
# faucet_walletaccount;
# INSERT INTO core_chain (
# id,
# chain_name,
# symbol,
# chain_id,
# rpc_url,
# decimals,
# explorer_url,
# logo_url,
# native_currency_name,
# poa,
# rpc_url_private,
# wallet_id,
# modal_url,
# max_gas_price,
# gas_multiplier,
# chain_type,
# is_testnet,
# is_active,
# enough_fee_multiplier,
# explorer_api_key,
# explorer_api_url
# )
# SELECT
# id,
# chain_name,
# symbol,
# chain_id,
# rpc_url,
# decimals,
# explorer_url,
# logo_url,
# native_currency_name,
# poa,
# rpc_url_private,
# wallet_id,
# modal_url,
# max_gas_price,
# gas_multiplier,
# chain_type,
# is_testnet,
# is_active,
# enough_fee_multiplier,
# explorer_api_key,
# explorer_api_url
# FROM
# faucet_chain;
# SELECT setval(pg_get_serial_sequence('"core_walletaccount"','id'), coalesce(max("id"), 1), max("id") IS NOT null) FROM "core_walletaccount";
# SELECT setval(pg_get_serial_sequence('"core_chain"','id'), coalesce(max("id"), 1), max("id") IS NOT null) FROM "core_chain";
# """, reverse_sql="")
]