agentzero07 commited on
Commit
2ac95fa
·
verified ·
1 Parent(s): 45d7119

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -39,7 +39,7 @@ def get_weather(city: str) -> str:
39
  city: A string representing a valid city (e.g., 'Bangalore').
40
  """
41
  try:
42
- requests.get('https://api.weatherapi.com/v1/current.json?key=41d95dfc59fb499583443528250902&q=' + city + '&aqi=no')
43
  weatherJSON = response.json()
44
  cityName = weatherJSON.get('location').get('name')
45
  cityTemp = weatherJSON.get('current').get('temp_c')
 
39
  city: A string representing a valid city (e.g., 'Bangalore').
40
  """
41
  try:
42
+ response = requests.get('https://api.weatherapi.com/v1/current.json?key=41d95dfc59fb499583443528250902&q=' + city + '&aqi=no')
43
  weatherJSON = response.json()
44
  cityName = weatherJSON.get('location').get('name')
45
  cityTemp = weatherJSON.get('current').get('temp_c')