Giter Site home page Giter Site logo

gis-weather's Introduction

ReadMe

Gis Weather

Dependencies

Used Python3 and GTK3

  • python3-gi (python-gobject)
  • python3-gi-cairo
  • gir1.2-gtk-3.0 (gtk3)

Recommends:

  • gir1.2-rsvg-2.0 (librsvg)

Features

  • View weather for several days
  • Detailed weather forecast for today and tomorrow
  • Fast switching between cities
  • Select the background and theme weather icons
  • "Compass" with the wind direction, with adjustable angle of rotation
  • Highlighting the high wind
  • Support weather services:
    • Gismeteo.com
    • OpenWeatherMap.org
    • Yr.no
  • Support SVG and widget scale
  • Indicator to panel
  • Presets

How to Install

What's New

https://github.com/RingOV/gis-weather/wiki/What's-New

Feedback

If you find bug, want translate, have issues?

Please mail to [email protected]

Links

Source Code (GitHub) - https://github.com/RingOV/gis-weather

deb, rpm, exe, tar.gz - https://sourceforge.net/projects/gis-weather/

AUR - https://aur.archlinux.org/packages/gis-weather/

NoobsLAB - http://www.noobslab.com/2014/05/gis-weather-widget-for-linux-desktop.html

Donations:

If you like the software, don't forget to donate to further development of it!

https://github.com/RingOV/gis-weather/wiki/Donate

gis-weather's People

Contributors

jasonb42 avatar jhooverman avatar ringov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gis-weather's Issues

Why can't show all info in English?

In my os:

locale
LANG=en_HK.UTF-8
LANGUAGE=en_HK:en
LC_CTYPE="en_HK.UTF-8"
LC_NUMERIC="en_HK.UTF-8"
LC_TIME="en_HK.UTF-8"
LC_COLLATE="en_HK.UTF-8"
LC_MONETARY="en_HK.UTF-8"
LC_MESSAGES="en_HK.UTF-8"
LC_PAPER="en_HK.UTF-8"
LC_NAME="en_HK.UTF-8"
LC_ADDRESS="en_HK.UTF-8"
LC_TELEPHONE="en_HK.UTF-8"
LC_MEASUREMENT="en_HK.UTF-8"
LC_IDENTIFICATION="en_HK.UTF-8"
LC_ALL=

Why not all characters are shown in English?
https://i.stack.imgur.com/noeSs.png

Wind units: Beaufort scale

It would be great if Beaufort scale was added to wind units. I think that many people living close to a sea would appreciate this.

Update frequency too long

Really enjoying this widget in general, thank you for the design.

I do find a minimum update frequency of 60 minutes much too long. At least in my area, the weather is much more variable than that -- I often find that if I do a manual refresh, the updated temperature can jump by 5°C or more.

Even if the weather service only updates its data once per hour, which seems unlikely, then that would mean that the widget could be almost 2 hours behind. I understand not wanting to hammer the weather service with constant data requests, but surely updating every 10 or 15 minutes wouldn't be an issue? It could still be set to upd_time = 60 by default but allow users a minimum setting of 10.

Thanks.

Weather.com: invalid location code for any location

Using Gis Weather 0.7.3 under Ubuntu 14.10: the applications says "invalid location code" when using the weather.com weather service, no matter which location is used. It even happens with the city code from the Gis Weather Setup dialog example.

gis-weather doesn't start

Is there is a way to run gis-weather in Wheezy - I get the following lines in terminal:

Traceback (most recent call last):
File "/usr/share/gis-weather/gis-weather.py", line 757, in expose
weather1 = get_weather()
File "/usr/share/gis-weather/gis-weather.py", line 413, in get_weather
if app.show_edit_dialog():
File "/usr/share/gis-weather/gis-weather.py", line 1506, in show_edit_dialog
dialog, entrybox, treeview, bar_err, bar_ok, bar_label, combobox_weather_lang, weather_lang_list, combobox_service, grid_appid, entrybox_appid = city_id_dialog.create(self.window_main, APP_PATH, service);
File "/usr/share/gis-weather/dialogs/city_id_dialog.py", line 109, in create
ui.add_from_file(os.path.join(APP_PATH, "dialogs","city_id_dialog.ui"))
File "/usr/lib/python3/dist-packages/gi/types.py", line 43, in function
return info.invoke(_args, *_kwargs)
gi._glib.GError: Unhandled tag: 'packing'

Check for new version (gz)
Traceback (most recent call last):
File "/usr/share/gis-weather/gis-weather.py", line 704, in redraw
check_updates()
File "/usr/share/gis-weather/gis-weather.py", line 462, in check_updates
if diff_versions.diff(v.split('.'), new_ver):
File "/usr/share/gis-weather/utils/diff_versions.py", line 7, in diff
new_ver = fix_digits(new_ver)
File "/usr/share/gis-weather/utils/diff_versions.py", line 21, in fix_digits
if len(i) < 2:
TypeError: object of type 'int' has no len()


Python3 version: 3.2.3 and all dependencies have been installed. Thanks in advance.

crashes un startup after configuering station

[studio@bahiahost ~]$ gis-weather
Gis Weather 0.8.4.17
Pasta de Configuração:
/home/studio/.config/gis-weather/gw_config1.json
/usr/share/gis-weather/gis-weather.py:1576: DeprecationWarning: Gtk.Window.set_has_resize_grip is deprecated
self.window_main.set_has_resize_grip(False)
/usr/share/gis-weather/gis-weather.py:1635: DeprecationWarning: Gtk.Window.set_opacity is deprecated
self.window_main.set_opacity(opacity)
Tamanho da interface:
largura = 500 altura = 320 incluindo travessão = 20
/usr/share/gis-weather/gis-weather.py:1587: DeprecationWarning: Gtk.Widget.is_composited is deprecated
if not self.window_main.is_composited():
Sua tela suporta transparência
/usr/share/gis-weather/gis-weather.py:832: DeprecationWarning: Gdk.cairo_create is deprecated
self.cr = Gdk.cairo_create(self.get_window())

Conseguir condições do tempo para 5 dias
Baixando https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?lang=en&city=30167
OK
atualizados no servidor 06:00
carregou as condições do tempo 09:04
Próxima atualização em 60 minha


Verifique se há nova versão (gz)
Você está usando a versão mais recente


Morto

DeprecationWarning: Gtk.Window

lubuntu 22.04
Gis Weather 0.8.4.18

some DeprecationWarning

$  gis-weather 
Gis Weather 0.8.4.18
Папка конфигурации:
    /home/johndoe/.config/gis-weather/gw_config1.json
/usr/share/gis-weather/gis-weather.py:643: DeprecationWarning: Gtk.StatusIcon.set_from_file is deprecated
  self.indicator.set_from_file(os.path.join(APP_PATH, "icon.png"))
/usr/share/gis-weather/gis-weather.py:645: DeprecationWarning: Gtk.StatusIcon.set_visible is deprecated
  self.indicator.set_visible(True)
/usr/share/gis-weather/gis-weather.py:1580: DeprecationWarning: Gtk.Window.set_has_resize_grip is deprecated
  self.window_main.set_has_resize_grip(False)
/usr/share/gis-weather/gis-weather.py:1639: DeprecationWarning: Gtk.Window.set_opacity is deprecated
  self.window_main.set_opacity(opacity)
Размеры виджета:
    ширина = 521 высота = 225 в т.ч. отступ = 20
/usr/share/gis-weather/gis-weather.py:1591: DeprecationWarning: Gtk.Widget.is_composited is deprecated
  if not self.window_main.is_composited():
Ваш экран поддерживает прозрачность
> Получаю погоду на 3 дней                                                                                             
> Скачиваю https://services.gismeteo.ru/inform-service/inf_chrome/forecast/?lang=ru&city=4392                          
OK
> обновлено на сервере 12:00
> погода получена 14:37
> Следующее обновление через 60 мин
----------------------------------------
/usr/share/gis-weather/gis-weather.py:656: DeprecationWarning: Gtk.StatusIcon.get_size is deprecated
  self.draw_text_to_png(self.indicator.get_size(), text)
/usr/share/gis-weather/gis-weather.py:737: DeprecationWarning: Gtk.StatusIcon.set_tooltip_markup is deprecated
  self.indicator.set_tooltip_markup(markup)

Remote end closed connection without response (Can't download weather icons)

I build an User-Agent header before downloading the weather icons

96 import platform                                                                 
97 # -------------------- new --------------------                                 
98 from urllib.request import build_opener                                         
99 from urllib.request import install_opener                                       
100 # -------------------- end new ----------------                       
1267                     print ('pix_path: [' + pix_path + "]")                      
1268                     # ----------- new ------------------                        
1269                     opener = build_opener()                                     
1270                     opener.addheaders = [('User-Agent', 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.98 Safari/537.36 ')]
1271                     install_opener(opener)                                      
1272                     # ------------end new --------------       
1273                     urlretrieve(pix, pix_path)                                  

After this improvement everything works well ;-)

Best regards
Dieter

gis-weather can no longer download from Accuweather

The application just hangs, completely unresponsive, when trying to download from Accuweather.
If you start it from a terminal it does indicate that it is downloading, but neither completes nor times out.
I assume Accuweather has changed something on their end because gis-weather still works properly from gismeteo.

Using openweather.

Configuration asks for city code, but there is no city code. You have to use geo co-ordinates but that is not clear in the instriuctions.

Проблема с получением данных с Accuweather

Не обновляется погода с accuweather/

python /home/haron/lib/gis-weather/gis-weather.py
Gis Weather 0.8.0.15
/home/haron/lib/gis-weather/utils/localization.py:8: PyGIWarning: Gtk was imported without specifying a version first. Use gi.require_version('Gtk', '3.0') before import to ensure that the right version gets loaded.
  from gi.repository import Gtk
/home/haron/lib/gis-weather/gis-weather.py:54: PyGIWarning: PangoCairo was imported without specifying a version first. Use gi.require_version('PangoCairo', '1.0') before import to ensure that the right version gets loaded.
  from gi.repository import Gtk, GObject, Pango, PangoCairo, Gdk, GdkPixbuf, GLib
/home/haron/lib/gis-weather/gis-weather.py:57: PyGIWarning: AppIndicator3 was imported without specifying a version first. Use gi.require_version('AppIndicator3', '0.1') before import to ensure that the right version gets loaded.
  from gi.repository import AppIndicator3
/home/haron/lib/gis-weather/gis-weather.py:64: PyGIWarning: Rsvg was imported without specifying a version first. Use gi.require_version('Rsvg', '2.0') before import to ensure that the right version gets loaded.
  from gi.repository import Rsvg
Папка конфигурации:
    /home/haron/.config/gis-weather/gw_config2.json
Размеры виджета:
    ширина = 708 высота = 308 в т.ч. отступ = 0
Ваш экран поддерживает прозрачность
> Получаю погоду на 7 дней
> Скачиваю http://www.accuweather.com/ru/моё_местоположене/current-weather/322731
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/current-weather/322731
OK
> Скачиваю http://www.accuweather.com/ru/моё_местоположене/month/322731?view=table
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/overnight-weather-forecast/322731?day=2
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/morning-weather-forecast/322731?day=2
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/afternoon-weather-forecast/322731?day=2
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/evening-weather-forecast/322731?day=2
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/overnight-weather-forecast/322731?day=1
OK
> Скачиваю http://www.accuweather.com/en/моё_местоположене/morning-weather-forecast/322731?day=1
OK
1
[!] Невозможно скачать страницу, проверьте интернет соединение

Wind Chill

I have turned on the wind chill option, but I do not see it on the widget panel. Under what circumstances does it show? For example, right now the air temp is 10 degrees F and the wind is 8 mph which would be a wind chill of -2 degrees F. I do not see this value anywhere on the panel. Weather service is Accuweather, location is Aurora, CO USA, OS is Ubuntu 15.10 64bit.

Compatibility issue with Cinnamon 4.4.x and Groupped Window List

I'm using Arch Linux with Cinnamon 4.4.x and the applet Grouped Window List. Recently I started using gis-weather as well and at first everything seemed to be OK - until I put the computer to sleep (I don't shut it down).

Any program that was open and running BEFORE I put the computer to sleep, becomes unclickable after I wake it up. For instance, the programs I used most every single day are PCManFM and Firefox and therefore I rarely close them. Before I put the computer to sleep I usually minimize both of them. But after waking up none of their icons is clickable and therefore I can't maximize them.

The described problems can only be fixed by 2 ways: either by closing gis-weather (right click on it, choose "Close") or rebooting the computer. These problems happen only AFTER waking the computer up. They don't happen after rebooting.
I was using both widget and tray icon of gis-weather. I'm mentioning that bc I think it may be relevant.
Here's my system decription in case you need it:

[rado@arch]: ~>$ sysinfo
rado@arch
OS: Arch Linux
Kernel: x86_64 Linux 5.4.2-arch1-1
Uptime: 8h 58m
Packages: 1097
Shell: bash
Resolution: 1920x1080
DE: Cinnamon 4.4.4
WM: Muffin
WM Theme: Mint-Y-Brownish_for-Cinnamon-v4_by-rado84 (Cinnamox-Rhino)
GTK Theme: Mint-Y-Brownish_for-Cinnamon-v4_by-rado84 [GTK2/3]
Icon Theme: Humanity-Dark
Font: Noto Sans Bold 10
Disk: 627G / 1,5T (44%)
CPU: Intel Core i7-4770 @ 8x 3.9GHz [32.0°C]
GPU: GeForce GTX 1050 Ti
RAM: 1735MiB / 32038MiB

Gismeteo иконка

Появился новый статус "Снежные зёрна" - в большинстве тем вместо иконки NA.
Flat White:
2016-02-11 18-12-20
Default:
2016-02-11 18-15-40
Версия программы: 0.8.0

Display of pressure in inHG

Is is possible to change the unit display for pressure? In the US, the system used is inches of Mercury (inHG) and is displayed in a 4 digit number, with a decimal in between the second and third number.

Using Accuweather as my data source, I only see 1 inHG. Is there any way to get it to display the way it's used across the US ( 29.93 in vs 1 inHG)?

Would it also be possible to include an arrow to show whether the pressure is rising or falling, as indicated by the website?
gis-weather issue

Снова ошибка в accuweather

Моя версия 0.8.1 на винде 10 64-бит и на убунту 16.10 64-бит начиная с сегодняшнего дня выдает ошибку-исчезает виджет из работного плота!

Не работает за пределами России

Думаю, жестко прошит адрес www.gismeteo.ru, поэтому в Молдове, например, не работает - ибо:

  • на gismeteo.ru, из-за geo-ip, не пускает - только напрямую на gismeteo.md;
  • редирект c gismeteo.ru на gismeteo.md у них сломался, раньше работало, а сейчас 502 Bad Gateway
  • а возможности указать gismeteo.md нет - только номер города...

Может лучше бы полный URL дали бы возможность вводить, а не только код города?

Using gismeteo.com (with latest gis-weather 0.8.4), city name is shown in Russian

Using gismeteo.com (with latest gis-weather 0.8.4), the city name is shown in Russian (and it can't be edited in the location setup GUI), even though I'm not russian and I have the system language set to English. The indicator extended weather menu is also in Russian.

Also, the city I tried to add is not located in Russia either, and the "Language weather" setting from the Location dialog window is set to English.

Python 3.8 removed function

Since Python 3.8 update, the "Block Additional info" is not working anymore and the log displays this error :
if platform.dist()[0] == 'debian': AttributeError: module 'platform' has no attribute 'dist'

platform.dist() was deprecated and has been removed from Python 3.8.
To resolve the issue, I replaced it with :

import distro
if distro.linux_distribution()[0] == 'debian':

Status Dropdown Menu for Indicator just like Gnome's Weather Indicator

Hi RingOV,

As I love what you did with this Gis-Weather widget (especially that it works with AccuWeather which is the most accurate one for my location) I would like to share my changes to the code, maybe someone (or even you) will find it useful.

Attached file contains

Download (as I'm not able to upload to github for some reason)
http://pijulius.com/julius/gis-weather/gis-weather-indicator-dropdown-menu.zip

Stock icons will be used from the theme directory you choose for the indicator and if that directory doesn't exists it will fall back to default

The patch also will fix the position of the dropdown menus for the indicator to be correct ones (meaning open below the icon instead of over them depending where you mouse was when you clicked the icon).

Hope you will like/find these changes useful.

Regards,
Julius

Не работает Gis-Weather 0.8.4.17-1 из AUR (Manjaro Gnome 22.1.3)

Здравствуйте. После установки GIS-Weather из AUR в Manjaro при запуске возникает следующая ошибка:
File "/usr/bin/gis-weather", line 1582, in init
self.window_main.set_icon_from_file(os.path.join(APP_PATH, "icon.png"))
gi.repository.GLib.GError: g-file-error-quark: Не удалось открыть файл «/usr/bin/icon.png»: Нет такого файла или каталога (4)

Вероятно в сборке не хватает файлика.
Будьте так добры и соберите исправленную версию пожалуйста.

blurry icons

i checked out the icons that are provided in the app nice hd quality but the app displays them blurry

Cannot download forecast

Downloading http://api.openweathermap.org/data/2.5/weather?id=2147714&lang=en&units=metric&appid=9559bbcc116ae1f545e982984609c2bc
1
OK

Downloading http://api.openweathermap.org/data/2.5/forecast?id=2147714&lang=en&units=metric&appid=9559bbcc116ae1f545e982984609c2bc
Unable to download page, check the network connection

I believe my network connection is ok

The problem may be that they don't give away forecast data anymore
Other widgets, like screenlets, show the same error

Could somebody write a service script for weather.com
It seems the only forecast provider left providing forecast data

change to the weather menu not working

hello. I am using elementary OS 5.1.2 Hera and gis-weather version 0.8.4.1. When I try to change to the weather menu, nothing happens. Reinstalling the gis-weather does not correct the situation. How can I fix this?

Accuweather does not work in degrees F setting.

When trying to view my weather using Accuweather in the Fahrenheit setting for temperature units, gis-weather 0.8.1 fails with the following lines from the command line:

Traceback (most recent call last):
File "/usr/share/gis-weather/gis-weather.py", line 775, in expose
weather1 = get_weather()
File "/usr/share/gis-weather/gis-weather.py", line 436, in get_weather
return data.get_weather(service)
File "/usr/share/gis-weather/services/data.py", line 78, in get_weather
return accuweather.get_weather()
File "/usr/share/gis-weather/services/accuweather.py", line 486, in get_weather
t_f[0][0] = F_to_C(t_f[0][0])
TypeError: 'tuple' object does not support item assignment

Check for new version (deb)
You are using the latest version


Gis-weather using Accuweather works when I change the temperature units to Celsius.

weather not refreshing

The weather is set to update every 30 minutes, but it is not. I have to manually refresh it.

Configuration file renewal

I had a strange issue with forecast icons disappearing when enabling the today block.
It had nothing to do with size or padding or what WM I used.
So I backed up ~/.config/gis-weather/gw_config1.json, (it contained city codes and the key)
restarted gis-weather and configured it all again (it created a new gw_config1.json file)
and this time NO MORE issues. Very happy moment.
It could well be that also the personal configuration file goes through changes,
and we had many of them lately.
So from time to time this may need to have a fresh start.
Many thanks to the developer for giving a new life to this,
I think, the best of all weather apps. Well done

Display more than one location at the same time

As far as I understood gis-weather will display the weather conditions for only one location. If I would like to switch to another, I will have to right-click, then select Location and enable the next. Will it be possible to add an option to allow to let gis-weather two or three locations at the same time?

Gis-weather 0.8.2.5 stop working!

Installed on kubuntu 18.04 and worked with no problems 3 weeks, but from 3 days after starting hangs with getting weather....not responded to nothing! The only way to stop is killing process!

Hides when Super + D

It hides when I press super + D. Something similar used to happen in conky but I was able to mitigate by changing the config files.

How do you change the widget style?

I am running Debian with Openbox. On executing gis-weather and choosing the city code, the default widget is displayed and there are no options to change it.

Night Time icons shown only

Hi
With the new version 0.8.3.4 on Ubuntu 16.04 Gnome-Flashback
Using Openweather.org
Only night time icons are shown regardless of time.
I'd rather have day time only icons so
I replaced all night icons with day ones in one of the themes
That is not very satisfactory though
Is there some tweak I can do in the code?
regards Rolf

Error message after check for new version.

Gis Weather 0.8.0
Папка конфигурации:
/home/sergio/.config/gis-weather/gw_config1.json
Размеры виджета:
ширина = 684 высота = 320 в т.ч. отступ = 20
Скриншот сохранен в /home/sergio/.config/gis-weather/main_screenshot.png
Ваш экран не поддерживает прозрачность

Получаю погоду на 7 дней
Скачиваю http://www.gismeteo.ru/city/weekly/4992
OK
обновлено на сервере 21:00
погода получена 00:03

Следующее обновление через 30 мин

Проверяю наличие новой версии (deb)
Traceback (most recent call last):
File "/usr/share/gis-weather/gis-weather.py", line 704, in redraw
check_updates()
File "/usr/share/gis-weather/gis-weather.py", line 462, in check_updates
if diff_versions.diff(v.split('.'), new_ver):
File "/usr/share/gis-weather/utils/diff_versions.py", line 7, in diff
new_ver = fix_digits(new_ver)
File "/usr/share/gis-weather/utils/diff_versions.py", line 21, in fix_digits
if len(i) < 2:
TypeError: object of type 'int' has no len()

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.