-
-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'rename-core-assets' into create-naming-convention-docs
- Loading branch information
Showing
42 changed files
with
686 additions
and
423 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
storage: | ||
postgres: | ||
postgres_db: | ||
username: | ||
env: DAGSTER_PG_USERNAME | ||
password: | ||
env: DAGSTER_PG_PASSWORD | ||
hostname: | ||
env: DAGSTER_PG_HOST | ||
db_name: | ||
env: DAGSTER_PG_DB | ||
port: 5432 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
113 changes: 113 additions & 0 deletions
113
migrations/versions/1ceb9897fd34_add_data_maturity_to_eia923m_tables.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
"""add data_maturity to eia923m tables | ||
Revision ID: 1ceb9897fd34 | ||
Revises: f11241c9292d | ||
Create Date: 2023-10-26 16:30:33.771381 | ||
""" | ||
import sqlalchemy as sa | ||
from alembic import op | ||
|
||
# revision identifiers, used by Alembic. | ||
revision = '1ceb9897fd34' | ||
down_revision = 'f11241c9292d' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
with op.batch_alter_table('boiler_fuel_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_boiler_fuel_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_boiler_fuel_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_boiler_fuel_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_boiler_fuel_monthly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_boiler_fuel_monthly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_boiler_fuel_yearly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_boiler_fuel_yearly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_fuel_receipts_costs_monthly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_fuel_receipts_costs_monthly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_fuel_receipts_costs_yearly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_fuel_receipts_costs_yearly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_generation_fuel_combined_monthly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_generation_fuel_combined_monthly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_generation_fuel_combined_yearly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_generation_fuel_combined_yearly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_generation_monthly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_generation_monthly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_generation_yearly_eia923', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_generation_yearly_eia923_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
with op.batch_alter_table('denorm_plants_utilities_eia', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('data_maturity', sa.Text(), nullable=True, comment='Level of maturity of the data record. Some data sources report less-than-final data. PUDL sometimes includes this data, but use at your own risk.')) | ||
batch_op.create_foreign_key(batch_op.f('fk_denorm_plants_utilities_eia_data_maturity_data_maturities'), 'data_maturities', ['data_maturity'], ['code']) | ||
|
||
# ### end Alembic commands ### | ||
|
||
|
||
def downgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
with op.batch_alter_table('denorm_plants_utilities_eia', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_plants_utilities_eia_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_generation_yearly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_generation_yearly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_generation_monthly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_generation_monthly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_generation_fuel_combined_yearly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_generation_fuel_combined_yearly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_generation_fuel_combined_monthly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_generation_fuel_combined_monthly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_fuel_receipts_costs_yearly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_fuel_receipts_costs_yearly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_fuel_receipts_costs_monthly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_fuel_receipts_costs_monthly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_boiler_fuel_yearly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_boiler_fuel_yearly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_boiler_fuel_monthly_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_boiler_fuel_monthly_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('denorm_boiler_fuel_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_denorm_boiler_fuel_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
with op.batch_alter_table('boiler_fuel_eia923', schema=None) as batch_op: | ||
batch_op.drop_constraint(batch_op.f('fk_boiler_fuel_eia923_data_maturity_data_maturities'), type_='foreignkey') | ||
batch_op.drop_column('data_maturity') | ||
|
||
# ### end Alembic commands ### |
35 changes: 35 additions & 0 deletions
35
migrations/versions/3313ca078f4e_demand_hourly_pa_ferc714_report_date_.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
"""demand_hourly_pa_ferc714.report_date can't be null | ||
Revision ID: 3313ca078f4e | ||
Revises: 1ceb9897fd34 | ||
Create Date: 2023-11-02 15:48:50.477585 | ||
""" | ||
import sqlalchemy as sa | ||
from alembic import op | ||
|
||
# revision identifiers, used by Alembic. | ||
revision = '3313ca078f4e' | ||
down_revision = '1ceb9897fd34' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
with op.batch_alter_table('demand_hourly_pa_ferc714', schema=None) as batch_op: | ||
batch_op.alter_column('report_date', | ||
existing_type=sa.DATE(), | ||
nullable=False) | ||
|
||
# ### end Alembic commands ### | ||
|
||
|
||
def downgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
with op.batch_alter_table('demand_hourly_pa_ferc714', schema=None) as batch_op: | ||
batch_op.alter_column('report_date', | ||
existing_type=sa.DATE(), | ||
nullable=True) | ||
|
||
# ### end Alembic commands ### |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.