Re: Showstopper desktop runtime issue

From: Joao De Almeida Pereira <jdealmeidapereira(at)pivotal(dot)io>
To: Dave Page <dpage(at)pgadmin(dot)org>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, Murtuza Zabuawala <murtuza(dot)zabuawala(at)enterprisedb(dot)com>, pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>, Akshay Joshi <akshay(dot)joshi(at)enterprisedb(dot)com>, Neel Patel <neel(dot)patel(at)enterprisedb(dot)com>, Ashesh Vashi <ashesh(dot)vashi(at)enterprisedb(dot)com>, Robert Eckhardt <reckhardt(at)pivotal(dot)io>
Subject: Re: Showstopper desktop runtime issue
Date: 2018-03-22 18:27:47
Message-ID: CAE+jjan6rjyLAtq03-CCvzgbatHk2yWDec-ZvdjZuwHPum54-Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hello Hackers

In the PoC we did with Electron last month this was the point where we
stopped

What did we accomplish:
- Use Electron as a runtime and packaging solution for the application
- Support opening new windows when the preferences ask for them
- Make the application generally work
- Use Chrome as a default browser for the application
- Building scripts for all platforms using `yarn`, please review Readme
- The packaged Python version is 3.6 to Mac and Linux, and 3.4 to Windows
- In our point of view it is a simpler way to generate the installers

Work in progress:
- No random port for the server, so you can only start 1 instance per
machine
- Tab support, there is no native support for tabs in Electron. It is
possible to do that, and eventually you will see a option in the menu to
create a new tab, but for this PoC we decided to disable the creation of
tabs. Tabs need to be implemented using HTML and cannot be ripped of from
the current window, like in Chrome
- Did not test in CentOS, but tested in Ubuntu and it is working (We tried
but the electron required GLIBC 2.25 that was not on the version of CentOS
that we had)
- In Linux despite the fact that we close the window, the application is
still running and need to be killed by hand
- We didn't test Debugger opening in new window
- Loading screen has no reference to pgAdmin
- No logging file for the runtime
- Windows we are using python 3.4 and using prior version of psycopg2
2.5.6 and pycrypto 2.6.1 (The version of psycopg2 is not the correct one,
this is because we couldn't find a precompile version of psycopg2)
- This is just a spike and the code looks pretty messy. This need to be
changed in order to make it more readable and have some tests around it
- Murtuza and Fahar were not able to run the application in Windows
- Khushboo was not able to run Ubuntu version

Given this was the status at the time, we need to pick and choose what we
really want to implement right out of the box and what could be postponed.
In order to generate Windows build and ensure that the Linux build is
working we need so help. If we could have access to the machines that you
use to build pgAdmin or access to the venv folder that is generated in
these machines we could try to create a build from that.

The changes we produced still applies cleanly on master and can be found
in: https://github.com/greenplum-db/pgadmin4/tree/electron-over-master

Thanks
Victoria & Joao

On Thu, Mar 22, 2018 at 12:58 PM Dave Page <dpage(at)pgadmin(dot)org> wrote:

> On Thu, Mar 22, 2018 at 4:28 PM, Dave Page <dpage(at)pgadmin(dot)org> wrote:
>
>>
>> 2) This option is not very appealing to me, because we would be pilling
>>>> code into the QT portion of the application, that I hope we remove in the
>>>> future, that currently is untested to solve a problem caused by a Window
>>>> Manager......
>>>> I would be more in favor of creating a Application Indicator that would
>>>> support 2 actions, Kill running pgAdmins and launch the browser to access
>>>> them. There is a lot of interesting websites that talk about this, and how
>>>> to develop. I had to download one to have a docker indicator..... But as I
>>>> said in a previous thread, I believe that this should be a 3rd party
>>>> application and not a first class citizen on pgAdmin, as the majority of
>>>> the ones that I found are.
>>>>
>>>
>>> I can't comment on the specific ways to sort it out, but I think
>>> *basing* things in option 2 is by far the best option. If it's just an
>>> additional add-on that can be made a dependency of the packages it's not a
>>> huge problem (provided this add-on is available on the major platforms like
>>> rhel, ubuntu, debian of course)
>>>
>>
>> It would just be a modified version of what we have. Instead of having an
>> icon in the system tray, we'd probably have multiple Start Menu icons to
>> replace the tray icon menu. They would have to signal a running instance to
>> do something, or become a new instance and then do the something if nothing
>> is running already.
>>
>
> Of course, another option here might be to figure out that we're running
> under Gnome/GTK at runtime, and if so, create an indicator icon and menu
> instead of the tray icon. That is, apparently, what Skype and other similar
> apps do now. The indicator icons go on the right of the top menu bar (kinda
> like where tray icons go on macOS).
>
>
> --
> Dave Page
> Blog: http://pgsnake.blogspot.com
> Twitter: @pgsnake
>
> EnterpriseDB UK: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Akshay Joshi 2018-03-23 05:36:31 Re: v3.0 release on hold
Previous Message Dave Page 2018-03-22 16:58:46 Re: Showstopper desktop runtime issue