<div dir="ltr">Package: postgresql-9.4-postgis-2.2<br>Version: 2.2.2+dfsg-5.pgdg+1<br>Severity: normal<br><br>Hello, <br><br>I work for Heroku Postgres, a service provider for postgres. We make available postgis to our customers, some of whom are using 2.0, 2.1 and 2.2 versions of postgis on major versions of postgres including 9.2, 9.3, 9.4 and 9.5. <br><br>A situation we have seen is where a user has a 9.4 database with postgis 2.1 that would like to run pg_upgrade to 9.5. The upgrade fails, as no postgis 2.1 package or binaries exist for 9.5.<br><br>To allow this upgrade to succeed, we must install postgresql-9.4-postgis-2.2 alongside postgresql-9.4-postgis-2.1, which allows ALTER EXTENSION postgis UPDATE to work, which clears the way for pg_upgrade to 9.5 to work as expected. <br><br>With the latest release of postgis 2.3, however, these packages are no longer able to be installed:<br><br>> # apt-get install postgresql-9.4-postgis-2.2 postgresql-9.4-postgis-2.1<br>> Reading package lists... Done<br>> Building dependency tree<br>> Reading state information... Done<br>> Some packages could not be installed. This may mean that you have<br>> requested an impossible situation or if you are using the unstable<br>> distribution that some required packages have not yet been created<br>> or been moved out of Incoming.<br>> The following information may help to resolve the situation:<br>> The following packages have unmet dependencies:<br>>  postgresql-9.4-postgis-2.2 : Depends: postgresql-9.4-postgis-2.2-scripts but it is not going to be installed<br>> E: Unable to correct problems, you have held broken packages.<br><br>This appears to be from postgresql-9.4-postgis-2.1 depending on postgresql-9.4-postgis-scripts, which depends on postgresql-9.4-postgis-2.3-scripts, which conflicts with postgresql-9.4-postgis-2.2-scripts:<br><br>> # apt-cache depends postgresql-9.4-postgis-2.1<br>> postgresql-9.4-postgis-2.1<br>>   Depends: libc6<br>>   Depends: libgdal1h<br>>   Depends: libgeos-c1<br>>   Depends: liblwgeom-2.1.8<br>>   Depends: libproj0<br>>   Depends: libxml2<br>>   Depends: postgresql-9.4<br>>   Depends: postgresql-9.4-postgis-scripts<br>>   Suggests: postgis<br>>   Recommends: postgresql-contrib-9.4<br>>   Breaks: postgis<br>> # apt-cache depends postgresql-9.4-postgis-scripts<br>> postgresql-9.4-postgis-scripts<br>>   Depends: postgresql-9.4-postgis-2.3-scripts<br>> # apt-cache depends postgresql-9.4-postgis-2.3-scripts<br>> postgresql-9.4-postgis-2.3-scripts<br>>   Recommends: postgresql-9.4-postgis-2.3<br>>   Conflicts: postgresql-9.4-postgis-2.2-scripts<br>>   Breaks: postgresql-9.4-postgis-scripts<br>>   Replaces: postgresql-9.4-postgis-scripts<br><br>This is surprising, as we have been successfully installing and using postgis 2.0, 2.1 and 2.2 packages with the latest postgis-scripts package satisfying dependencies for all versions for some time. <br><br>Is each version of postgis-scripts incompatible with other versions of postgis? Is postgis-2.3-scripts not backwards compatible with postgis-2.2?<div><br></div><div>I have found <a href="https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837294">https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837294</a> and am not sure of the reasoning behind "We're using Conflicts instead of Breaks/Replaces because the source packages is also used in PGDG where multiple versions are provided." as it breaks the multiple version use case that pgdg allows. </div><div><br></div><div>Thanks,</div><div>Greg<br><br>-- System Information:<br>Debian Release: stretch/sid<br>  APT prefers unstable<br>  APT policy: (500, 'unstable')<br>Architecture: amd64 (x86_64)<br><br>Kernel: Linux 4.4.15-moby (SMP w/2 CPU cores)<br>Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)<br></div></div>