-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4385 from MidwestFurryFandom/prereg-2024
Merge updates from AnthroCon and MFF
- Loading branch information
Showing
136 changed files
with
4,830 additions
and
1,655 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 |
---|---|---|
|
@@ -35,4 +35,6 @@ uber/static/fonts/free3of9.pkl | |
config*.ini | ||
uber.ini | ||
.env | ||
.venv/ | ||
.venv/ | ||
ssl-cert.pem | ||
ssl-key.pem |
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,17 @@ | ||
include: | ||
- template: 'Workflows/Branch-Pipelines.gitlab-ci.yml' | ||
|
||
stages: | ||
- build | ||
|
||
build: | ||
image: docker:26.1.4 | ||
stage: build | ||
services: | ||
- docker:26.1.4-dind | ||
variables: | ||
IMAGE_TAG: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG | ||
script: | ||
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY | ||
- docker build -t $IMAGE_TAG . | ||
- docker push $IMAGE_TAG |
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 |
---|---|---|
|
@@ -19,12 +19,12 @@ | |
Attendee.email == '[email protected]' | ||
).order_by(AdminAccount.id).first() | ||
|
||
if admin: | ||
# Make it easier to do site section testing at the command line | ||
cherrypy.session = {'account_id': admin.id} | ||
print('Logged in as {} <{}>'.format(admin.attendee.full_name, admin.attendee.email)) | ||
elif c.DEV_BOX: | ||
print('INFO: Could not find Test Developer admin account') | ||
if admin: | ||
# Make it easier to do site section testing at the command line | ||
cherrypy.session = {'account_id': admin.id} | ||
print('Logged in as {} <{}>'.format(admin.attendee.full_name, admin.attendee.email)) | ||
else: | ||
print('INFO: Could not find Test Developer admin account') | ||
|
||
except Exception as ex: | ||
print('ERROR: Could not initialize ubersystem environment') | ||
|
63 changes: 63 additions & 0 deletions
63
alembic/versions/37f79e6ccee7_artist_payout_method_field.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,63 @@ | ||
"""Artist payout method field | ||
Revision ID: 37f79e6ccee7 | ||
Revises: 93514f9f4520 | ||
Create Date: 2024-06-06 12:18:23.844115 | ||
""" | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = '37f79e6ccee7' | ||
down_revision = '93514f9f4520' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
from alembic import op | ||
import sqlalchemy as sa | ||
|
||
|
||
|
||
try: | ||
is_sqlite = op.get_context().dialect.name == 'sqlite' | ||
except Exception: | ||
is_sqlite = False | ||
|
||
if is_sqlite: | ||
op.get_context().connection.execute('PRAGMA foreign_keys=ON;') | ||
utcnow_server_default = "(datetime('now', 'utc'))" | ||
else: | ||
utcnow_server_default = "timezone('utc', current_timestamp)" | ||
|
||
def sqlite_column_reflect_listener(inspector, table, column_info): | ||
"""Adds parenthesis around SQLite datetime defaults for utcnow.""" | ||
if column_info['default'] == "datetime('now', 'utc')": | ||
column_info['default'] = utcnow_server_default | ||
|
||
sqlite_reflect_kwargs = { | ||
'listeners': [('column_reflect', sqlite_column_reflect_listener)] | ||
} | ||
|
||
# =========================================================================== | ||
# HOWTO: Handle alter statements in SQLite | ||
# | ||
# def upgrade(): | ||
# if is_sqlite: | ||
# with op.batch_alter_table('table_name', reflect_kwargs=sqlite_reflect_kwargs) as batch_op: | ||
# batch_op.alter_column('column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# else: | ||
# op.alter_column('table_name', 'column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# | ||
# =========================================================================== | ||
|
||
|
||
def upgrade(): | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
op.add_column('art_show_application', sa.Column('payout_method', sa.Integer(), server_default='25184922', nullable=False)) | ||
# ### end Alembic commands ### | ||
|
||
|
||
def downgrade(): | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
op.drop_column('art_show_application', 'payout_method') | ||
# ### end Alembic commands ### |
59 changes: 59 additions & 0 deletions
59
alembic/versions/3fe61d6e4837_add_admin_notes_for_promo_codes.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,59 @@ | ||
"""Add admin notes for promo codes | ||
Revision ID: 3fe61d6e4837 | ||
Revises: 459045b27a25 | ||
Create Date: 2024-07-10 01:38:14.558297 | ||
""" | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = '3fe61d6e4837' | ||
down_revision = '459045b27a25' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
from alembic import op | ||
import sqlalchemy as sa | ||
|
||
|
||
|
||
try: | ||
is_sqlite = op.get_context().dialect.name == 'sqlite' | ||
except Exception: | ||
is_sqlite = False | ||
|
||
if is_sqlite: | ||
op.get_context().connection.execute('PRAGMA foreign_keys=ON;') | ||
utcnow_server_default = "(datetime('now', 'utc'))" | ||
else: | ||
utcnow_server_default = "timezone('utc', current_timestamp)" | ||
|
||
def sqlite_column_reflect_listener(inspector, table, column_info): | ||
"""Adds parenthesis around SQLite datetime defaults for utcnow.""" | ||
if column_info['default'] == "datetime('now', 'utc')": | ||
column_info['default'] = utcnow_server_default | ||
|
||
sqlite_reflect_kwargs = { | ||
'listeners': [('column_reflect', sqlite_column_reflect_listener)] | ||
} | ||
|
||
# =========================================================================== | ||
# HOWTO: Handle alter statements in SQLite | ||
# | ||
# def upgrade(): | ||
# if is_sqlite: | ||
# with op.batch_alter_table('table_name', reflect_kwargs=sqlite_reflect_kwargs) as batch_op: | ||
# batch_op.alter_column('column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# else: | ||
# op.alter_column('table_name', 'column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# | ||
# =========================================================================== | ||
|
||
|
||
def upgrade(): | ||
op.add_column('promo_code', sa.Column('admin_notes', sa.Unicode(), server_default='', nullable=False)) | ||
|
||
|
||
def downgrade(): | ||
op.drop_column('promo_code', 'admin_notes') |
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,61 @@ | ||
"""Add replyto for emails | ||
Revision ID: 459045b27a25 | ||
Revises: b4d9068d50c3 | ||
Create Date: 2024-06-30 01:37:29.917475 | ||
""" | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = '459045b27a25' | ||
down_revision = 'b4d9068d50c3' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
from alembic import op | ||
import sqlalchemy as sa | ||
|
||
|
||
|
||
try: | ||
is_sqlite = op.get_context().dialect.name == 'sqlite' | ||
except Exception: | ||
is_sqlite = False | ||
|
||
if is_sqlite: | ||
op.get_context().connection.execute('PRAGMA foreign_keys=ON;') | ||
utcnow_server_default = "(datetime('now', 'utc'))" | ||
else: | ||
utcnow_server_default = "timezone('utc', current_timestamp)" | ||
|
||
def sqlite_column_reflect_listener(inspector, table, column_info): | ||
"""Adds parenthesis around SQLite datetime defaults for utcnow.""" | ||
if column_info['default'] == "datetime('now', 'utc')": | ||
column_info['default'] = utcnow_server_default | ||
|
||
sqlite_reflect_kwargs = { | ||
'listeners': [('column_reflect', sqlite_column_reflect_listener)] | ||
} | ||
|
||
# =========================================================================== | ||
# HOWTO: Handle alter statements in SQLite | ||
# | ||
# def upgrade(): | ||
# if is_sqlite: | ||
# with op.batch_alter_table('table_name', reflect_kwargs=sqlite_reflect_kwargs) as batch_op: | ||
# batch_op.alter_column('column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# else: | ||
# op.alter_column('table_name', 'column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# | ||
# =========================================================================== | ||
|
||
|
||
def upgrade(): | ||
op.add_column('automated_email', sa.Column('replyto', sa.Unicode(), server_default='', nullable=False)) | ||
op.add_column('email', sa.Column('replyto', sa.Unicode(), server_default='', nullable=False)) | ||
|
||
|
||
def downgrade(): | ||
op.drop_column('email', 'replyto') | ||
op.drop_column('automated_email', 'replyto') |
76 changes: 76 additions & 0 deletions
76
alembic/versions/56d684473beb_separate_promo_code_and_art_show_agent_.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,76 @@ | ||
"""Separate promo code and art show agent codes. | ||
Revision ID: 56d684473beb | ||
Revises: 7c43e4352bb0 | ||
Create Date: 2024-05-31 03:19:53.022061 | ||
""" | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = '56d684473beb' | ||
down_revision = '7c43e4352bb0' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
from alembic import op | ||
import sqlalchemy as sa | ||
from sqlalchemy.dialects import postgresql | ||
import residue | ||
|
||
|
||
try: | ||
is_sqlite = op.get_context().dialect.name == 'sqlite' | ||
except Exception: | ||
is_sqlite = False | ||
|
||
if is_sqlite: | ||
op.get_context().connection.execute('PRAGMA foreign_keys=ON;') | ||
utcnow_server_default = "(datetime('now', 'utc'))" | ||
else: | ||
utcnow_server_default = "timezone('utc', current_timestamp)" | ||
|
||
def sqlite_column_reflect_listener(inspector, table, column_info): | ||
"""Adds parenthesis around SQLite datetime defaults for utcnow.""" | ||
if column_info['default'] == "datetime('now', 'utc')": | ||
column_info['default'] = utcnow_server_default | ||
|
||
sqlite_reflect_kwargs = { | ||
'listeners': [('column_reflect', sqlite_column_reflect_listener)] | ||
} | ||
|
||
# =========================================================================== | ||
# HOWTO: Handle alter statements in SQLite | ||
# | ||
# def upgrade(): | ||
# if is_sqlite: | ||
# with op.batch_alter_table('table_name', reflect_kwargs=sqlite_reflect_kwargs) as batch_op: | ||
# batch_op.alter_column('column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# else: | ||
# op.alter_column('table_name', 'column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# | ||
# =========================================================================== | ||
|
||
|
||
def upgrade(): | ||
op.create_table('art_show_agent_code', | ||
sa.Column('id', residue.UUID(), nullable=False), | ||
sa.Column('app_id', residue.UUID(), nullable=False), | ||
sa.Column('attendee_id', residue.UUID(), nullable=True), | ||
sa.Column('code', sa.Unicode(), server_default='', nullable=False), | ||
sa.Column('cancelled', residue.UTCDateTime(), nullable=True), | ||
sa.ForeignKeyConstraint(['app_id'], ['art_show_application.id'], name=op.f('fk_art_show_agent_code_app_id_art_show_application')), | ||
sa.ForeignKeyConstraint(['attendee_id'], ['attendee.id'], name=op.f('fk_art_show_agent_code_attendee_id_attendee'), ondelete='SET NULL'), | ||
sa.PrimaryKeyConstraint('id', name=op.f('pk_art_show_agent_code')), | ||
sa.UniqueConstraint('attendee_id', name=op.f('uq_art_show_agent_code_attendee_id')) | ||
) | ||
op.drop_constraint('fk_art_show_application_agent_id_attendee', 'art_show_application', type_='foreignkey') | ||
op.drop_column('art_show_application', 'agent_code') | ||
op.drop_column('art_show_application', 'agent_id') | ||
|
||
|
||
def downgrade(): | ||
op.add_column('art_show_application', sa.Column('agent_id', postgresql.UUID(), autoincrement=False, nullable=True)) | ||
op.add_column('art_show_application', sa.Column('agent_code', sa.VARCHAR(), server_default=sa.text("''::character varying"), autoincrement=False, nullable=False)) | ||
op.create_foreign_key('fk_art_show_application_agent_id_attendee', 'art_show_application', 'attendee', ['agent_id'], ['id'], ondelete='SET NULL') | ||
op.drop_table('art_show_agent_code') |
Oops, something went wrong.