composer: PEAR installer doesn't work

My composer.json:

	"require": {
		"pear-pear.php.net/Calendar": "0.5.5",
		"pear-pear.php.net/Date_Holidays_Germany": "0.1.2",
	}
	
	"repositories": [
		{
			"type": "pear",
			"url": "https://pear.php.net/"
		}
	]

Output of composer diagnose:

Checking composer.json: WARNING
require.zendframework/zenddiagnostics : unbound version constraints (dev-master) should be avoided
require.pear-pear.php.net/XML_Util : exact version constraints (1.4.2) should be avoided if the package follows semantic versioning
require.adodb/adodb-php : exact version constraints (v5.19) should be avoided if the package follows semantic versioning
require.phpoffice/phpexcel : exact version constraints (1.7.9) should be avoided if the package follows semantic versioning
require.apache/log4php : exact version constraints (2.3.0) should be avoided if the package follows semantic versioning
require.ezyang/htmlpurifier : exact version constraints (4.7.0) should be avoided if the package follows semantic versioning
require.fpdf/fpdf : exact version constraints (1.81) should be avoided if the package follows semantic versioning
require.phpseclib/phpseclib : exact version constraints (2.0.3) should be avoided if the package follows semantic versioning
require.muz/mive : unbound version constraints (>=1.0.5) should be avoided
require.elasticsearch/elasticsearch : exact version constraints (1.0.x-dev) should be avoided if the package follows semantic versioning
require.pimple/pimple : unbound version constraints (>=v2.0.0) should be avoided
require.muz/docx-api : unbound version constraints (dev-trunk) should be avoided
require.simplesamlphp/simplesamlphp : exact version constraints (1.14.0) should be avoided if the package follows semantic versioning
require.bower-asset/bootstrap : exact version constraints (3.3.4) should be avoided if the package follows semantic versioning
require.bower-asset/respond-minmax : exact version constraints (1.4.2) should be avoided if the package follows semantic versioning
require.bower-asset/html5shiv : exact version constraints (3.7.2) should be avoided if the package follows semantic versioning
require.bower-asset/retina.js : exact version constraints (1.3.0) should be avoided if the package follows semantic versioning
require.bower-asset/mjolnic-bootstrap-colorpicker : exact version constraints (2.1.2) should be avoided if the package follows semantic versioning
Checking platform settings: OK
Checking git settings: OK
Checking http connectivity to packagist: OK
Checking https connectivity to packagist: OK
Checking github.com oauth access: OK
Checking disk free space: OK
Checking pubkeys:
Tags Public Key Fingerprint: 57815BA2 7E54DC31 7ECC7CC5 573090D0  87719BA6 8F3BB723 4E5D42D0 84A14642
Dev Public Key Fingerprint: 4AC45767 E5EC2265 2F0C1167 CBBB8A2B  0C708369 153E328C AD90147D AFE50952
OK
Checking composer version: OK

When I run this command:

composer update

I get the following output:

Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
  - Installing pear-pear.php.net/archive_tar (1.4.2)
    Loading from cache
  - Installing pear-pear.php.net/console_getopt (1.4.1)
    Loading from cache
  - Installing pear-pear.php.net/structures_graph (1.1.1)
    Loading from cache
  - Installing pear-pear.php.net/xml_util (1.3.0)
    Loading from cache
  - Installing pear-pear.php.net/pear (1.10.1)
    Loading from cache
  - Installing pear-pear.php.net/xml_parser (1.3.6)
    Loading from cache
  - Installing pear-pear.php.net/versioncontrol_svn (0.4.0)
    Loading from cache
...

PEAR repository from https://pear.php.net could not be loaded. Undefined index: channel
Updating dependencies

...

  Problem 1
    - module requires pear-pear.php.net/calendar 0.5.5 -> no matching package found.
    - module requires pear-pear.php.net/calendar 0.5.5 -> no matching package found.

   
...

And I expected this to happen:

Seams that after PEAR update package XML_Util from 2017-02-22 the composer install manager for PEAR is not longer working.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 15 (9 by maintainers)

Most upvoted comments

Is PEAR not dead yet?

The best way forward really would be to make sure you migrate those packages you rely on to packagist, like a bunch of pear packages have been ported already https://packagist.org/packages/pear/ - that way you can eventually drop the pear repo entirely from your composer.json. @cweiske has been doing some of that too AFAIK, it basically just needs someone willing to do the work.

Anyway I merged #6202, if you can confirm that it works after a composer self-update --snapshot that’d be nice. I will try and do a release next week as there are a couple other fixes in the pipeline…