fschwartzer commited on
Commit
ba96f19
1 Parent(s): 525f2c4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -80,11 +80,11 @@ with st.sidebar:
80
  selected_coords = st.selectbox('Selecione Coordenadas', ['Random', 'Custom'])
81
 
82
  if selected_coords == 'Custom':
83
- custom_address = st.text_input('Enter Address', 'Your Address Here')
84
  radius_visible = True # Show radius slider for custom coordinates
85
  # No need to initialize max_distance_all here
86
  else:
87
- custom_address = "Porto Alegre, Brazil" # Default address
88
  radius_visible = False # Hide radius slider for random coordinates
89
  max_distance_all = 0 # Initialize max_distance_all here
90
 
@@ -97,7 +97,7 @@ with st.sidebar:
97
  location = gmaps.geocode(custom_address)[0]['geometry']['location']
98
  custom_lat, custom_lon = location['lat'], location['lng']
99
  except (IndexError, GeocoderTimedOut):
100
- st.error("Error: Unable to geocode the provided address. Please check and try again.")
101
 
102
  # Slider for setting the zoom level
103
  if selected_coords == 'Custom':
 
80
  selected_coords = st.selectbox('Selecione Coordenadas', ['Random', 'Custom'])
81
 
82
  if selected_coords == 'Custom':
83
+ custom_address = st.text_input('Informe o endereço', 'Endereço desejado aqui')
84
  radius_visible = True # Show radius slider for custom coordinates
85
  # No need to initialize max_distance_all here
86
  else:
87
+ custom_address = "Lajeado, Rio Grande do Sul, Brazil" # Default address
88
  radius_visible = False # Hide radius slider for random coordinates
89
  max_distance_all = 0 # Initialize max_distance_all here
90
 
 
97
  location = gmaps.geocode(custom_address)[0]['geometry']['location']
98
  custom_lat, custom_lon = location['lat'], location['lng']
99
  except (IndexError, GeocoderTimedOut):
100
+ st.error("Erro: Não foi possível geocodificar o endereço fornecido. Por favor, verifique e tente novamente.")
101
 
102
  # Slider for setting the zoom level
103
  if selected_coords == 'Custom':