Hacks icon indicating copy to clipboard operation
Hacks copied to clipboard

Notify users if an upgrade is available

Open waseem18 opened this issue 8 years ago • 5 comments

When a user runs the application, notify user that an update is available (if update is available) Best way of doing this?

@tibyte What do you think about it?

waseem18 avatar Dec 21 '15 18:12 waseem18

The "head through the wall" approach would be having a update program that compares version numbers (in a file eg.: ".hacks/version") with raw.github content..., and then download the new version, replacing the old.

when doing that we should also keep in mind that we could save the sources in a json file (".hacks/sources") together with the way to fetch them (if they have similarities). Then we would just need to update that if we find a new source.

mtib avatar Dec 21 '15 19:12 mtib

related: what do you think of doing it like this: https://github.com/waseem18/Hacks/commit/c625966b226173cd71ce38c1b406c6283d1d9639#diff-7524d17c38ed0b02a3dc699263d3ce94L232 ... so we could make that more dynamic

for fetchalg in [HackathonsList1, HackathonsList2, HackathonsList3, HackathonsList4]:
    try:
        fetchalg(data)
    except:
        pass

mtib avatar Dec 21 '15 19:12 mtib

this idea could revolutionize the project

as this already needs an internet connection, why don't we offer a server socket to which the client socket justs connects, sends it's location via the ip-api or via the cli... and the server responds with what currently the client would figure out. This way the client'd never have to upgrade and we could keep adding stuff!

then I realize

that I am currently working on too many websites, and this is probably not what you intended this program to be....

but it's an idea

mtib avatar Dec 21 '15 21:12 mtib

Actually I too thought of the same while building Hacks. I have also built a site on Appengine which would output Json content of Hackathon details with input as location.

I just didn't use it because I too was building too many websites and was not interested in building one more :grin:

But it's actually a good idea. And yeah, I have also access to internal API's of a couple of Hackathon listing websites. (I was asked to keep the details about internal API's to be confidential. So can't reveal it.)

So yeah! It would be really awesome to build it in this way :)

waseem18 avatar Dec 22 '15 02:12 waseem18

Next steps

So the next step forwards would be using python sockets to answer a clients request consisting of its location. This seems like we're building a smart telnet client/server, but that's exactly what I expected when reading:

A Linux terminal client to find upcoming Hackathons near you or at a particular location.

Concerning the Hackathons-Api's:

That be a nice long-term goal, to add as many other sources as possible.

My thoughts

The sources we currently have and the way we handle them would suffice. I believe it would be smarter to add new sources after the move to a server/client architecture.

My connections

I have some friends based in northern Germany, who run a "Hackspace". Maybe they can forward me some api for fetching info about german Hackathons.

mtib avatar Dec 22 '15 03:12 mtib