postgresql and pgAdmin4

Hi forum
I'm a long time postgres user, and would really like to be able to use pgAdmin4 in FreeBSD.
(pgAdmin3 has become seriously outdated, and no longer supports recent version/s of postgres.)
Sadly, there's no package for pgadmin4, so I search for information and try to follow the pgAdmin4 section on this page.
https://wiki.freebsd.org/PostgreSQL/Setup
I've tried doing this using both FBSD versions 13.3 and 14.0.
- Install the packages, upgrade pip, create the virtualenv, activate, then pip install pgAdmin4.
Seems this process fails at the same point, with this message :

Code:
ERROR: Failed building wheel for psutil
Failed to build psutil
ERROR: Could not build wheels for psutil, which is required to install pyproject.toml-based projects

I also tried to pip install psutil separately, which seems successful, then pip install pgadmin4
Sadly, same error as above.
Thanks for any tips or clues to do this the-right-way.
 
I search for information and try to follow the pgAdmin4 section on this page.
https://wiki.freebsd.org/PostgreSQL/Setup
I've tried doing this using both FBSD versions 13.3 and 14.0.
I found following installation guide: pgAdmin 4 on FreeBSD 14

In the howto pgadmin4 v8.1 is fetched, but it seems it is not available anymore. Try latest v8.5, or other supported versions.

Note: Getting pgadmin4 into ports is in progress, but dependency issues need to be resolved first (dependency port update and new ports required):

Bug 261652: [New Port] databases/pgadmin4: feature rich Open Source administration and de...
 
There should be psutil version number in the error message. If you do not install the exact version specified, the install process will anyway try to install the version it requires.
 
I found following installation guide: pgAdmin 4 on FreeBSD 14

In the howto pgadmin4 v8.1 is fetched, but it seems it is not available anymore. Try latest v8.5, or other supported versions.

Note: Getting pgadmin4 into ports is in progress, but dependency issues need to be resolved first (dependency port update and new ports required):

Bug 261652: [New Port] databases/pgadmin4: feature rich Open Source administration and de...

Seems like the fetch link is outdated and needs to be updated.
Simply go the link's directory and obtain the latest sources:


Not sure if "pgadmin4-8.11" can work with postgresql 16...
 
I am currently running version 8.9 (in server mode, in a separate jail).

Problem with this upgrade was, it explicitely requires psycopg[binary]==3.1.19, and this binary does -as usual- only exist for MacOS, Windows, Linux.
Other OS should use psycopg[c] - but that is not in the dependency-manifest.

If however you download the .tar.gz package, that contails a requirements.txt with the proper prereq. So then it did work in two steps:
$ pip install --no-deps /tmp/pgadmin4*.whl
$ pip install -r /tmp/requirements.txt # from .tar.gz package
 
As its not solved - came to the same issue, tried many many things, searched many many things - came to this issue solving answer ( ps. dont know what psycopg-binary does so you have to realize its not installed as currently no psycopg-binary is available for FreeBSD )
  • download pgadmin4.whl
  • wheel unpack <pgadmin4.whl>
  • edit METADATA file and remove "[binary]" from line where psycopq is listed as requirement
  • wheel pack <pgadmin4.whl>
  • pip install ./pgadmin4.whl
Link for binary
P.s. there are two psycopg-binary entries not one !
P.P.S - have not tried PMc option.
 
As its not solved - came to the same issue, tried many many things, searched many many things - came to this issue solving answer ( ps. dont know what psycopg-binary does so you have to realize its not installed as currently no psycopg-binary is available for FreeBSD )
  • download pgadmin4.whl
  • wheel unpack <pgadmin4.whl>
  • edit METADATA file and remove "[binary]" from line where psycopq is listed as requirement
  • wheel pack <pgadmin4.whl>
  • pip install ./pgadmin4.whl
Yeah that will probably also work.
 
As its not solved - came to the same issue, tried many many things, searched many many things - came to this issue solving answer ( ps. dont know what psycopg-binary does so you have to realize its not installed as currently no psycopg-binary is available for FreeBSD )
  • download pgadmin4.whl
  • wheel unpack <pgadmin4.whl>
  • edit METADATA file and remove "[binary]" from line where psycopq is listed as requirement
  • wheel pack <pgadmin4.whl>
  • pip install ./pgadmin4.whl
Link for binary
P.s. there are two psycopg-binary entries not one !
P.P.S - have not tried PMc option.

I don't see any line in METADATA containing psycopq. Is this a typo, and should be psycopg ?
(psycopg = PostgreSQL database adapter for python)

Perhaps these lines should be edited ?

Code:
Requires-Dist: psycopg[binary]==3.2.1; (sys_platform == "darwin" and platform_machine == "arm64" and platform_release >= "23.0") or (sys_platform == "darwin" and platform_machine != "arm64") or sys_platform != "darwin"
...
Requires-Dist: psycopg[binary]==3.1.19; sys_platform == "darwin" and platform_machine == "arm64" and platform_release < "23.0"
(Yes, I'm very new to python, and keen to get pgadmin4 working.)
 
Perhaps these lines should be edited ?

Code:
Requires-Dist: psycopg[binary]==3.2.1; (sys_platform == "darwin" and platform_machine == "arm64" and platform_release >= "23.0") or (sys_platform == "darwin" and platform_machine != "arm64") or sys_platform != "darwin"
...
Requires-Dist: psycopg[binary]==3.1.19; sys_platform == "darwin" and platform_machine == "arm64" and platform_release < "23.0"
Correct. It was a typo.

(psycopg = PostgreSQL database adapter for python)
Yes, but there also is psycopg-binary and psycopg-pool, these are optional components , this is why im saying: remmember you dont have psycopg-binary installed.
Also if you will do django - you might have issues as if i recal - psycopg-binary is needed so you have to use psycobg2 and postgresql 16 and im not sure if you can use pgadmin4 with this combination.
 
Back
Top