Git Product home page Git Product logo

ubuntuindicatorweather's Introduction

UbuntuIndicatorWeather Tag

Description

UbuntuIndicatorWeather is a very simple weather indicator for Ubuntu unity and Gnome 3. It is developed with Python and uses two web service calls Ip-api.com, Weather-api.madadipouya.com (based on Open Weather Map) to detect user's location and temperature respectively.

Dependencies

The indicator has dependencies for Python >= 2.7 and requires some Python libraries which are listed below

  • Python >= 2.7
  • Python gtk library
  • Gir1.2-appindicator3-0.1
  • Gir1.2-notify-0.7
  • Python urllib
  • Python json library
  • Python retry library

How to install

Via PPA (Ubuntu only version 0.7 and onwards)

You can add PPA repository for easy installation and be notified on updates. Add the following repository to your machine like this:

$ sudo add-apt-repository ppa:kasra-mp/ubuntu-indicator-weather

$ sudo apt-get update

To install the weather indicator run:

$ sudo apt-get install indicator-weather

Supported Ubuntu versions

  • Bionic Beaver 18.04 LTS
  • Zesty Zapus 17.04 (Until version 1.0)
  • Yakkety Yak 16.10 (Until version 0.9.0)
  • Xenial Xerus 16.04 LTS
  • Wily Werewolf 15.10 (Until version 0.8.2)
  • Vivid Vervet 15.04 (Until version 0.9.0)
  • Trusty Tahr 14.04 LTS

Supported architectures

  • i386
  • X64

Via .deb file

If you want to use older versions (< 0.7) of the indicator or install it on other Debian based distributions, you can download .deb package(s) from release section (link).

Via AUR (Arch Linux)

For Arch Linux, UbuntuIndicatorWeather is available on the Arch User Repository, under the package name ubuntu-indicator-weather (link)

Via .tar.gz file

For non-debian based distributions you can download .tar.gz files which consist of the source code of the indicator from release section (link).

Extract the content of the compressed file and run installation file with root permission.

$ sudo ./install.sh

Website

For more information please refer to Simple Weather Indicator website.

Screenshot

Simple Weather Indicator

Donate

You can always support, show appreciation by buying a cup of coffee :-)

paypal

Contact

License

License

Indicator Weather is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation.

Indicator Weather is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. http://www.gnu.org/licenses/

Author(s):

© 2015-2018 Kasra Madadipouya [email protected]

ubuntuindicatorweather's People

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  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

ubuntuindicatorweather's Issues

Pluralise "Preference" Menu Option

Line 75 of Indicator-Weather.py:

self.preference_item = Gtk.MenuItem("Preference")

should read

self.preference_item = Gtk.MenuItem("Preferences")

as there is more than one 'preference'.

17.10

Do you mind making a release version for 17.10 Artful Aardvark?

Can't alter any preferences on Ubuntu 16.04(PPA)

Attempting to set any of the preferences in 0.8.1 on Ubuntu 16.04 (via the ppa) fails.

Clicking the "OK" button triggers this error/warning:
Traceback (most recent call last): File "/usr/lib/ubuntu-indicator-weather/preference.py", line 65, in on_ok_button_clicked self.configuration.set_auto_start(str(switch_autostart.get_active()).title()) File "/usr/lib/ubuntu-indicator-weather/configuration.py", line 176, in set_auto_start return self.ini_start_up.set(Startup.SECTION_DESKTOP_ENTRY, Startup.SETTING_NAME_X_GNOME_AUTO_START_ENABLED, value.lower()) AttributeError: 'NoneType' object has no attribute 'set'

The Preferences window does not close, nor does the indicator get updated to reflect the requested change(s).

All other packages on this machine are up-to-date, FTR....

Frequently changes location

I put in the lat/long coordinates manually. Several times per day, it changes from showing the location I entered to showing various distant locations around the world, often in other languages.

I do Preferences > OK, and that fixes it for the moment. But I'd rather not have to do this regularly. Not sure which version I have, but I believe it's the latest in the PPA.

Ubuntu 16.10.

Indicator doesn't show any weather data when starting at system startup

indicator showing no weather information

The indicator works normally, however, if autostart is on, this is what I get after logging in to Ubuntu.

Possible reason: It seems that if the network connection is only established after the indicator loads, it cannot update, hence shows no weather data.

The network connection is set up in the next couple of seconds immediately, but sadly the indicator doesn't try to fetch the information right again afterwards, instead I have to wait long minutes or restart the application to get some weather data.

Crazy Weather Report

It seems sometimes weather-indicator simply goes mad. Even if it's pulling weather for wrong location, it shouldn't show something like this:

crazy-weather

At 80C human skin will start melting. What next? 2344 C ?

Location gets displayed as number

I've just installed indicator-weather 0.6 and it is displaying my location as "3343." I'm actually in Minneapolis, USA, and I believe it is detecting my location correctly. ip-api.com is accurate, and the temperature matches what it shows on openweathermap.org. I entered in my lat/lng manually, and the number changed to 2683. I'm not sure what this corresponds to. On openweathermap.org, my city is 5037649.

Please make refresh interval configurable via Preferences

I assume that the indicator is contacting the weather services not more frequently than once an hour. If this actually happens more frequently, then I would certainly like to reduce it to once an hour.

So, ideally, there should be a "Refresh interval" added to Preferences to allow users to set this to their liking. Some people may prefer to have refresh more frequently, like once in half an hour.

Indicator stopped working after installing tlp on 17.10

After having installed tlp (Linux Advanced Power Management), the weather indicator stopped working. When I try to launch it via terminal it gets stuck. After a while, when I hit Ctrl+C, it gives this:
^CTraceback (most recent call last):
File "/usr/bin/indicator-weather", line 259, in
indicator.main()
File "/usr/bin/indicator-weather", line 140, in main
self.get_weather()
File "/usr/lib/python2.7/dist-packages/retrying.py", line 49, in wrapped_f
return Retrying(*dargs, **dkw).call(f, *args, **kw)
File "/usr/lib/python2.7/dist-packages/retrying.py", line 220, in call
time.sleep(sleep / 1000.0)
KeyboardInterrupt

Is there any possiblity to make it work again? Thanks

Use integer values for temperatures

I don't think people really care about sub-integer temperatures. I mean, 17°C and 17.4°C is essentially the same temperature to me. Moreover, reporting temperature of long time periods with 0.1°C accuracy is not scientifically meaningful since the temperature will surely fluctuate during this time and through the region.

Rounding all temperatures to integer values instead removes some clutter from the app, making it more useful when you want to very quickly check the weather.

At the end, this is my personal taste. Feel free to close this issue. Thanks for this beautiful and useful app that you have made.

I filed the same issue with Forecastie recently.

Freezes when updating

Hello,

I'm in version 16.04 of Ubuntu and a few days ago I realize that the indicator weather stays frozen, doesnt respond. When I give it to update it is when it stays frozen, it does not allow to do anything else.
I have done some tests, and since it doesnt geolocate me well I put my GPS location. Well, when I dont have the geolocation on, it works (but it does not say exactly where I am), but when I put it manually, it causes it to freeze and not work. I have tried in the previous version to the current one and it works. What can happen?.
Greetings

The word "kilometre" is misspelled.

The proper English and International (as adopted by Bureau of Weights and Measures) spelling of the word "kilometre" is "kilometre" and not "kilometer" --- the latter is an Americanism and ought to be avoided. Here is the link to WikiPedia which explains this:

https://en.wikipedia.org/wiki/Kilometre

Actually, since the speed of wind is shown in "km/h" it makes sense to abbreviate the unit of visibility to "km" as well. If you use "km" and also switch the time to 24 hour default (as per #51 ) then the total width of the menu will be reduced, as a bonus :)

Cursor position is lost when entering Longitude and Latitude in Preferences

When entering the GPS coordinates for manual location one has to switch between Chrome running Google Maps application and indicator-weather's Preferences dialog. If both are visible simultaneously, then there is no problem, but if they happen to be on different workspaces, then one memorises the first 3-4 digits, then switches to Preferences and enters them. Then switches back to Google Maps and memorises the rest of the digits and switches back to Preferences in order to complete the process of entering the data. But at this step the cursor position is reset to the beginning of the field and so entering the remaining digits causes data corruption, i.e. the completely wrong number is entered.

So, the fix for this bug is simple: don't try to do anything clever with the line edit textbox containing the coordinates. Just accept whatever is entered there and validate it only when the user pressed OK to save the data.

Manual location

It would be nice to be able to set the location manually, as the automatic one is pretty off.

Add autostart option

Currently autostart is on the system level, need to be moved to user level and add an option to enable or disable it.

It doesn't start on Ubuntu 16.10

It doesn't start on a freshly installed Ubuntu 16.10
Error Message:

/usr/bin/indicator-weather:28: 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 as appIndicator Traceback (most recent call last): File "/usr/bin/indicator-weather", line 144, in <module> indicator = WeatherIndicator() File "/usr/bin/indicator-weather", line 63, in __init__ self.configuration = Configuration() File "/usr/lib/ubuntu-indicator-weather/configuration.py", line 29, in __init__ self.ini_start_up = self.__create_start_up_script_if_not_exist() File "/usr/lib/ubuntu-indicator-weather/configuration.py", line 49, in __create_start_up_script_if_not_exist if exc.errno != errno.EEXIST: NameError: global name 'errno' is not defined
Ubuntu 16.10
Linux 4.8.0.27
Python 2.7.12
Indicator-Weather 0.8-1ubuntu2

Option to toggle location

It would be nice to have an option to toggle whether or not the location is shown. I know where I am and sometimes the location name takes up a lot of space.

Popups contain errors

With the release of 1.0 this past weekend, the popups describing local weather are simply wrong. These popups are also extremely annoying and there is no way to turn them off.
Case in point: Today in my location (Graceville, FL) we have about 50% cloud cover yet the popups state that it is clear and sunny. Not sure if these popups are designed for those that never leave a windowless room but accuracy with local conditions would be appreciated along with the ability to turn the popups off.

Option to hide location name on the panel

For some locations , the name could be very long, thus occupying a vast horizontal space on the panel.

It would be nice if we can hide/toggle location name on the panel from the preference.

indicator-weather

Hide location should only hide location in the task bar

There are two places where one can see the location, the taskbar and the menu on click.
If the option to hide the location is enabled, this is hidden from both places, so the user cannot tell the location unless he goes to options again and disables this option.

In my opinion, the location should never be hidden from the menu, only from the taskbar.

Indicator Weather does not display temp nor any other data

Whenever I open indicator-weather the temperature does not populate, nor does the information in the dropdown. I've installed all of the needed dependencies as well as restarting the machine, and installing and uninstalling. I cannot find a solution. Screenshots have been attached.
indicator-weather
indicator-weather-dropdown-cropped

User can´t set the wind scale

Lines 169-174 uses a scale for wind but there is not an space in the GUI for user to set the wind scale he wants.Can you write some code to improve configurability of the project?

PPA install on 16.04 misses 'gi' dependency

The application won't start due to the following error:

Traceback (most recent call last): File "/usr/bin/indicator-weather", line 23, in <module> import gi ImportError: No module named gi

Installing the 'python-gi' solves the problem.

Add menu item in dash

At the moment Ubuntu users need to logout and login to indicator appears. Need to add the indicator item to dash, so user can launch the indicator directly without logout and login.

Update Ubuntu PPA

The current PPA doesn't have packages for Ubuntu 17.10 Artful Aardvark, and support for 17.04 Zesty Zapus ended on January 13th.

Preferences window not showing up in Ubuntu 14.04

The indicator runs successfully and shows a temperature. However, when I click on the 'Preference'(s) menu item in the indicator, no window is opened and I see this error in the terminal:

Traceback (most recent call last): File "/usr/bin/indicator-weather", line 94, in preference preference_dialog = Dialog() File "/usr/lib/ubuntu-indicator-weather/preference.py", line 23, in __init__ self.builder.add_from_file('/usr/share/ubuntu-indicator-weather/ui.glade') gi._glib.GError: /usr/share/ubuntu-indicator-weather/ui.glade: required gtk+ version 3.12, current version is 3.10

I see that my GTK+ version is too old. But is there a way to remove the requirement for gtk+ 3.12 so that people on Ubuntu 14.04 can also use the weather indicator?

As always, thank you very much for this nice and beautiful tool.

Show more weather info on indicator-dropdown

The old Ubuntu weather indicator(also written in python https://launchpad.net/weather-indicator) has very nice weather information displayed on indicator dropdown. It shows following information:

  1. Humidity
  2. Wind condition
  3. Sunrise/Sunset etc

weather-indicator-dropdown

The memory footprint is also very low; **~ 10-15MB**.

It uses earthtools.org (http://new.earthtools.org) to get location data and uses that location data with http://api.met.no to get sunrise/sunset info. Look at the source here: http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/wily/indicator-weather/wily/view/head:/bin/indicator-weather

Both services have deprecated (still working somehow). However for this kind of data we could always use OpenweatherMap api (http://openweathermap.org/api).

What do you think?

Ubuntu Desktop 18.10

I know Ubuntu Desktop 18.10 is not in the list of officially support versions. It does seem to work for me with two caveats: 1) the apt repository throws an error when running the update command, and 2) installing with the .deb package froze my machine requiring a hard reboot. After the reboot, it seems to work fine.

I don't know if this is expected in my Ubuntu version, but I thought I would note it.

Thanks,
Mike

Python-warnings polluting system logs

Can you please fix these warnings?

/usr/bin/indicator-weather:28: 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.

It's annoying and polluting my syslog.

Show time in 24 hour format (or at least add an option to allow this)

The subject says it all: the time of last update should be optionally shown in 24 hour format, not with those weird "pm" and "am" things.

Actually, what would be nice is if you could detect if the user selected 24 hour format for the time display in the GNOME or Unity settings and use that. But if that is too hard, then please just add an option in Preferences to switch between the standard 24 hours and the strange non-military am/pm formats.

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.