A PyQt5-based weather application that provides real-time weather updates and a 12-hour forecast for cities worldwide using the OpenWeatherMap API.
- User-Friendly GUI: A custom-designed interface using PyQt5.
- Country and City Selection: Select a country and city from dynamic dropdowns.
- Weather Information:
- Real-time temperature, wind speed, humidity, and pressure.
- Sunrise and sunset times (adjusted for the Tehran timezone).
- 12-Hour Forecast: Displays weather predictions and icons for the next 12 hours.
- Custom Window Controls: Frameless and draggable window.
- Python 3.x
- PyQt5
requests
librarypycountry
pytz
- OpenWeatherMap API key
- Clone the repository:
git clone https://github.com/AmirRghp/Weather-App.git cd Weather-App
- Install dependencies:
pip install -r requirements.txt
- Replace the API key in Search function:
API_KEY = "your_api_key_here"
- Ensure the city.list.json file is in the project directory:
- This file contains data for countries and cities used to populate the dropdowns.
- Run the application:
python main.py
- Select a country and city from the dropdown menus.
- Click the Search button to fetch the weather data.
- View the results and 12-hour forecast displayed in the GUI.
Here is a screenshot of the Weather App:
Check out a video demonstration of the app: