Skip to content
Merged
Show file tree
Hide file tree
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
8 changes: 8 additions & 0 deletions tcsocket/app/management.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,3 +308,11 @@ def update_socket_images(conn):
print(f'Unable to find {img_thumb_key}, returned 404')
else:
r.raise_for_status()


@patch
def increase_company_name_field_length(conn):
"""
increase company name length from 63 to 255 characters
"""
conn.execute('ALTER TABLE companies ALTER COLUMN name TYPE VARCHAR(255)')
2 changes: 1 addition & 1 deletion tcsocket/app/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Company(Base):
public_key = Column(String(20), index=True, nullable=False, unique=True)
private_key = Column(String(50), index=True, nullable=False)

name = Column(String(63), unique=True)
name = Column(String(255), unique=True)
domains = Column(ARRAY(String(255)))

name_display = Column(sa_enum(NameOptions), default=NameOptions.first_name_initial, nullable=False)
Expand Down
8 changes: 4 additions & 4 deletions tcsocket/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ aiohttp==3.8.1
aiopg==1.3.3
aioredis==1.3.1
arq==0.22
boto3==1.20.28
boto3==1.20.44
cchardet==2.1.7
gunicorn==20.1.0
python-dateutil==2.8.2
pillow==9.0.0
pydantic[email]==1.9.0
raven==6.10.0
requests==2.27.0
requests==2.27.1
uvloop==0.16.0
ipython==7.31.0
pgcli==3.2.0
ipython==7.31.1
pgcli==3.3.1
ipython-sql==0.4.0
yarl==1.7.2