Skip to content

Commit

Permalink
Merge pull request #4 from henrykironde/titleset_id
Browse files Browse the repository at this point in the history
Check tileset_id length
  • Loading branch information
henrykironde authored Apr 26, 2024
2 parents 50bcca8 + 3d0f9b5 commit 59b92a1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions upload_mapbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@ def get_credentials():
filename_without_extension = os.path.splitext(os.path.basename(file_path))[0]
tileset_id = filename_without_extension

if len(tileset_id) >= 32:
raise Exception(f"Length of {tileset_id} is more than or at the limit of 32")
# Step 3: Create an upload to matbox
upload_data = uploader.create_upload(s3_credentials, tileset_id)
upload_id = upload_data['id']
Expand Down

0 comments on commit 59b92a1

Please sign in to comment.