Building runtime-only pgAdmin4
Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
I want to build pgAdmin4 runtime only; no browser interface, but ... When I built the executable following the directions for the runtime version and invoked pgAdmin4 it displays a dialog box asking for the python and application paths: $ pgAdmin4 Python path: "/usr/bin/python2" Python Home: "" Webapp path: "/usr/local/bin/pgAdmin4.py" Traceback (most recent call last): File "/usr/local/bin/pgAdmin4.py", line 23, in import config ImportError: No module named config "Failed to launch the application server, server thread exiting." Installed here are: python-2.7.13, python3-3.6.0, and python3-PyQt5-5.6. I would appreciate advice on how to successfully build a runtime-only pgAdmin4. TIA, Rich
Re: Building runtime-only pgAdmin4
От:
Dave Page <dpage@pgadmin.org>
Дата:
On Wed, Mar 29, 2017 at 10:51 AM, Rich Shepard wrote: > I want to build pgAdmin4 runtime only; no browser interface, but ... > > When I built the executable following the directions for the runtime > version and invoked pgAdmin4 it displays a dialog box asking for the python > and application paths: > > $ pgAdmin4 Python path: "/usr/bin/python2" > Python Home: "" > Webapp path: "/usr/local/bin/pgAdmin4.py" > Traceback (most recent call last): > File "/usr/local/bin/pgAdmin4.py", line 23, in > import config > ImportError: No module named config > "Failed to launch the application server, server thread exiting." > > Installed here are: python-2.7.13, python3-3.6.0, and python3-PyQt5-5.6. > > I would appreciate advice on how to successfully build a runtime-only > pgAdmin4. Have you followed the instructions in the README? https://git.postgresql.org/gitweb/?p=pgadmin4.git;a=blob;f=README -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, Dave Page wrote: > Have you followed the instructions in the README? Dave, Yes. in the section titled, Building. "To build the runtime, the following packages must be installed: - QT 4.6 or above (older versions may work, but haven't been tested). - Python 2.6 or above." Installed here are python3-PyQt5-5.6 and python3-3.6.0. "Assuming both qmake and python-config are in the path: $ cd $PGADMIN4_SRC/runtime $ qmake Project MESSAGE: Building for QT5+... $ make ..." Followed this by 'make install' Rich
Re: Building runtime-only pgAdmin4
От:
Dave Page <dpage@pgadmin.org>
Дата:
On Wed, Mar 29, 2017 at 12:19 PM, Rich Shepard wrote: > On Wed, 29 Mar 2017, Dave Page wrote: > >> Have you followed the instructions in the README? > > > Dave, > > Yes. in the section titled, Building. > > "To build the runtime, the following packages must be installed: > > - QT 4.6 or above (older versions may work, but haven't been tested). > - Python 2.6 or above." > > Installed here are python3-PyQt5-5.6 and python3-3.6.0. > > "Assuming both qmake and python-config are in the path: > > $ cd $PGADMIN4_SRC/runtime > $ qmake > Project MESSAGE: Building for QT5+... > $ make > ..." > > Followed this by 'make install' What about the Python parts? -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, Dave Page wrote: > What about the Python parts? Dave, Other than Python-2.6 or more recent I don't see other python parts in the README. Installed here are: python-2.7.13 python-dateutil python3-3.6.0 python3-PyQt5-5.6 python3-sip-4.18 Please show me what I'm missing. Thanks, Rich
Re: Building runtime-only pgAdmin4
От:
Dave Page <dpage@pgadmin.org>
Дата:
On Wed, Mar 29, 2017 at 12:46 PM, Rich Shepard wrote: > On Wed, 29 Mar 2017, Dave Page wrote: > >> What about the Python parts? > > > Dave, > > Other than Python-2.6 or more recent I don't see other python parts in the > README. Installed here are: > > python-2.7.13 > python-dateutil > python3-3.6.0 > python3-PyQt5-5.6 > python3-sip-4.18 > > Please show me what I'm missing. There's a large section entitled: "Configuring the Python Environment", followed by another one describing how to configure the two parts to work together. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, Dave Page wrote: > There's a large section entitled: "Configuring the Python Environment", > followed by another one describing how to configure the two parts to work > together. Dave, OK. The README I downloaded with pgAdmin-4.1.1 is 84 lines long, separated into four sections: Architecture, Building, Support, and Project info. I'll go to the web site and try again. Many thanks, Rich
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, Rich Shepard wrote: > I'll go to the web site and try again. Downloaded the 1.3 tarball and the README file is 310 lines long. I'm sure the required information is in there. Thanks, Dave, Rich
Re: Building runtime-only pgAdmin4
От:
marcelo <marcelo.nicolet@gmail.com>
Дата:
Hi Rich Please, tell the list the new building process results. I cannot follow it without errors and strange errors. TIA Marcelo On 29/03/17 15:14, Rich Shepard wrote: > On Wed, 29 Mar 2017, Rich Shepard wrote: > >> I'll go to the web site and try again. > > Downloaded the 1.3 tarball and the README file is 310 lines long. > I'm sure > the required information is in there. > > Thanks, Dave, > > Rich > >
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, marcelo wrote: > Please, tell the list the new building process results. I cannot follow it > without errors and strange errors. Marcelo, One question I had asked a while ago has been anwered: one needs to install the python web framework, flask, and SQLAlchemy even if the end use is from the command line (the runtime build). Interesting. I upgraded the SlackBuilds.org packages for virtualenv, virtualenv-clone, and virtualenvwrapper and sourced /usr/bin/virtualenvwrapper.sh (Slackware puts executables in /usr/bin/ rather than /usr/local/bin/ and postgres is installed in /usr/lib/postgresql/9.6/bin -- at least for the currently installed version -- rather than /usr/local/pgsql/bin; the postgres data directory is in /var/lib/pgsql/data/). Next, I created a pgAdmin4 virtual environment as directed in step 3. Within that environment I ran pip3 as in step 4, but since installation of many of the tools requires root privileges I ran [root@salmo ~]# pip install -r /opt/pgadmin4-1.3/requirements.txt. This failed because it was looking for python-2.x rather than 3.x and tried installing a very old version of SQLAlchemy-1.0.8 where the current version is something like 1.0.14. So, I still cannot build pgAdmin4 on this host. Rich
Re: Building runtime-only pgAdmin4
От:
Ashesh Vashi <ashesh.vashi@enterprisedb.com>
Дата:
On Thu, Mar 30, 2017 at 2:33 AM, Rich Shepard <rshepard@appl-ecosys.com> wrote:
On Wed, 29 Mar 2017, marcelo wrote:Please, tell the list the new building process results. I cannot follow it
without errors and strange errors.
Marcelo,
One question I had asked a while ago has been anwered: one needs to
install the python web framework, flask, and SQLAlchemy even if the end use
is from the command line (the runtime build). Interesting.
I upgraded the SlackBuilds.org packages for virtualenv, virtualenv-clone,
and virtualenvwrapper and sourced /usr/bin/virtualenvwrapper.sh (Slackware
puts executables in /usr/bin/ rather than /usr/local/bin/ and postgres is
installed in /usr/lib/postgresql/9.6/bin -- at least for the currently
installed version -- rather than /usr/local/pgsql/bin; the postgres data
directory is in /var/lib/pgsql/data/).
Next, I created a pgAdmin4 virtual environment as directed in step 3.
Within that environment I ran pip3 as in step 4, but since installation of
many of the tools requires root privileges I ran
[root@salmo ~]# pip install -r /opt/pgadmin4-1.3/requirements.txt. This
Please try pip3 (on some system, for python 3, it uses pip3).
--
Thanks & Regards,
Ashesh Vashi
EnterpriseDB INDIA: Enterprise PostgreSQL Company
failed because it was looking for python-2.x rather than 3.x and tried
installing a very old version of SQLAlchemy-1.0.8 where the current version
is something like 1.0.14.
So, I still cannot build pgAdmin4 on this host.
Rich
--
Sent via pgadmin-support mailing list (pgadmin-support@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-support
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Thu, 30 Mar 2017, Ashesh Vashi wrote: >> Within that environment I ran pip3 as in step 4, but since installation >> of ... > Please try pip3 (on some system, for python 3, it uses pip3). Ashesh, Please see above line in original message. Rich
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, Rich Shepard wrote: > Within that environment I ran pip3 as in step 4, but since installation of > many of the tools requires root privileges I ran [root@salmo ~]# pip > install -r /opt/pgadmin4-1.3/requirements.txt. This failed because it was > looking for python-2.x rather than 3.x and tried installing a very old > version of SQLAlchemy-1.0.8 where the current version is something like > 1.0.14. Accomplished step 4 in (pgadmin4) [rshepard@salmo /opt/pgadmin4-1.3]$ using the command: su -c 'pip3 install -r requirements.txt' Now on to the config file. Rich
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Wed, 29 Mar 2017, Rich Shepard wrote: > Now on to the config file. Copied the config_local.py from the README to that filename in /opt/pgAdmin4/web/. Then cd'd to /opt/pgAdmin4/runtime/ and ran qmake. Despite having python3-3.6.0 and Qt5-5.5.1 installed, and all the requirements installed using pip3, qmake saw none of this: $ qmake Project MESSAGE: Building for QT4... Project MESSAGE: Using QWebKit... Project MESSAGE: Project MESSAGE: ************************************** WARNING ************************************** Project MESSAGE: * It is strongly advised that Qt 5.5.0 or later is used to build the pgAdmin runtime. Project MESSAGE: ************************************************************************************* Project MESSAGE: Project MESSAGE: Building for Linux/Mac... Project MESSAGE: Using /home/rshepard/.virtualenvs/pgadmin4/bin/python-config Project MESSAGE: Python2 detected. I'm giving up. I need to get work done and this is taking too much of my day. Rich
Re: Building runtime-only pgAdmin4
От:
marcelo <marcelo.nicolet@gmail.com>
Дата:
Near exactly the problems I confronted. I don't know why this complex and troublesome build process. Thank you, Rich. On 29/03/17 19:33, Rich Shepard wrote: > On Wed, 29 Mar 2017, Rich Shepard wrote: > >> Now on to the config file. > > Copied the config_local.py from the README to that filename in ven > /opt/pgAdmin4/web/. > > Then cd'd to /opt/pgAdmin4/runtime/ and ran qmake. Despite having > python3-3.6.0 and Qt5-5.5.1 installed, and all the requirements installed > using pip3, qmake saw none of this: > > $ qmake > Project MESSAGE: Building for QT4... > Project MESSAGE: Using QWebKit... > Project MESSAGE: Project MESSAGE: > ************************************** WARNING > ************************************** > Project MESSAGE: * It is strongly advised that Qt 5.5.0 or later is > used to build the pgAdmin runtime. > Project MESSAGE: > ************************************************************************************* > Project MESSAGE: Project MESSAGE: Building for Linux/Mac... > Project MESSAGE: Using > /home/rshepard/.virtualenvs/pgadmin4/bin/python-config > Project MESSAGE: Python2 detected. > > I'm giving up. I need to get work done and this is taking too much > of my > day. > > Rich > >
Re: Building runtime-only pgAdmin4
От:
Dave Page <dpage@pgadmin.org>
Дата:
On Wed, Mar 29, 2017 at 8:20 PM, marcelo wrote: > Near exactly the problems I confronted. > I don't know why this complex and troublesome build process. Because it's a complex piece of software, and unless you're familiar with Python is probably going to be a daunting task to configure manually. Why are you trying to build by hand? It's really not expected that end-users do that; it should only be packagers and developers who have to do it that way. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company
Re: Building runtime-only pgAdmin4
От:
Rich Shepard <rshepard@appl-ecosys.com>
Дата:
On Thu, 30 Mar 2017, Dave Page wrote: > Why are you trying to build by hand? It's really not expected that > end-users do that; it should only be packagers and developers who have to > do it that way. While SlackBuilds.org has a working build script for pgadmin3 no one has undertaken the task of providing one for pgAdmin4. Postgres and related tools are not part of the Slackware distribution; mariadb has replaced mysql in that. So, those of us who would like to try pgAdmin4 must build piece-by-piece. I've no idea about other distributions or OSes so can write only for myself and other Slackware users. Rich
Re: Building runtime-only pgAdmin4
От:
marcelo <marcelo.nicolet@gmail.com>
Дата:
In the first place, I am a developer. So, what is the question if I try to build some software from the sources? Second: there is no pgAdmin4 binaries for Debian and derived distros. Lastly, mr Developer: some years ago, I contributed to porting Postgres 8.3 to QnX. So, it's supposed I could read source code and adapt it to a very special environment like that. On 30/03/17 10:31, Dave Page wrote: > On Wed, Mar 29, 2017 at 8:20 PM, marcelo wrote: >> Near exactly the problems I confronted. >> I don't know why this complex and troublesome build process. > Because it's a complex piece of software, and unless you're familiar > with Python is probably going to be a daunting task to configure > manually. > > Why are you trying to build by hand? It's really not expected that > end-users do that; it should only be packagers and developers who have > to do it that way. >
Re: Building runtime-only pgAdmin4
От:
Dave Page <dpage@pgadmin.org>
Дата:
On Thu, Mar 30, 2017 at 11:55 AM, marcelo wrote: > In the first place, I am a developer. So, what is the question if I try to > build some software from the sources? > > Second: there is no pgAdmin4 binaries for Debian and derived distros. > > Lastly, mr Developer: some years ago, I contributed to porting Postgres 8.3 > to QnX. So, it's supposed I could read source code and adapt it to a very > special environment like that. There's no need for sarcasm. I have no idea of your abilities or what you are trying to achieve. Had your goal been to just run pgAdmin, then I might have been able to help you find a pre-built package to save you having to do more work. Unfortunately much I would like to have them, we do not yet have Debian packages. In the meantime, my best suggestion is to either build from source (which I realise is not straightforward), or you could download the EnterpriseDB PostgreSQL 9.6 installers from http://www.enterprisedb.com/products/pgdownload.do#linux, install them, and then shutdown and disable the database server. Those packages include a build of pgAdmin that should run on most modern Linuxes (though I honestly don't know about Slackware which Rich was trying to use). -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company