rmcgirr83 / contactadmin

This form allows guests and/or registered users to either send an email or send a PM to admins or make a Post in a designated forum. It also overrides the default contact admin link found on the forum. A port of the phpBB 3.0.x mod “Contact Board Administration”. Latest version requires at least PHP 8.0.
GNU General Public License v2.0
7 stars 9 forks source link

Require of phpbb/phpbb makes problems with composer installation #6

Closed Crizz0 closed 7 years ago

Crizz0 commented 7 years ago

Hi,

I've tried to install your extension via composer.

I've added "rmcgirr83/contactadmin": "1.1.*" to my phpBB composer.json and run ../composer.phar update, but then phpBB tries to install the extension and your extension tries to install phpBB, which won't work.

This led to:

$ ../composer.phar update
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for phpbb/phpbb No version set (parsed as 1.0.0) -> satisfiable by phpbb/phpbb[No version set (parsed as 1.0.0)].
    - rmcgirr83/contactadmin 1.1.0 requires phpbb/phpbb >=3.1.3, <3.4 -> satisfiable by phpbb/phpbb[3.1.3, 3.1.4].
    - Can only install one of: phpbb/phpbb[3.1.3, No version set (parsed as 1.0.0)].
    - Can only install one of: phpbb/phpbb[3.1.4, No version set (parsed as 1.0.0)].
    - Installation 

I think you should remove this part: https://github.com/rmcgirr83/contactadmin/blob/master/composer.json#L22 and online keep line #30

With reference to: https://area51.phpbb.com/docs/dev/31x/extensions/tutorial_basics.html#composer-json

Regards

PS: Tagging the versions here on github, would be nice, too. :) 1.1.1 and higher is missing. :(

rmcgirr83 commented 7 years ago

So the question then is why wasn't this pointed out during validation? Doesn't installing via CLI require this?

Crizz0 commented 7 years ago

The cli is different to composer. It is just the same function, which will be activated when you click install in ACP. Composer downloads the extension, updates it and removes unused files, but does not click the install button.

paul999 commented 7 years ago

@rmcgirr83 Because it is added by titania, so we don't see that it exists already when you submit it :). You should, at least untill 3.3, not add the phpbb/phpbb requirment, but only have it in soft-require if you submit your extension to packagist.

rmcgirr83 commented 7 years ago

Okies and thanks for the explanation. Fixed