stechstudio / laravel-zipstream

Easily create Zip files on-the-fly and provide a streaming download
MIT License
419 stars 60 forks source link

Unable to install package. #106

Closed younus93 closed 10 months ago

younus93 commented 11 months ago

Hi, I am using laravel 9. When i try to install the package, i get the below error.

`Problem 1

jszobody commented 11 months ago

Do you have maennchen/zipstream-php already in your composer.json file? Error message sounds like you have that locked to a specific version, which conflicts.

younus93 commented 11 months ago

Thanks for replying.

No. I dont have that package. These are the packages I currently use.


        "php": "^8.0.2",
        "asantibanez/livewire-calendar": "dev-master",
        "aws/aws-sdk-php": "^3.255",
        "calebporzio/sushi": "^2.4",
        "codeat3/blade-fluentui-system-icons": "^1.31",
        "codeat3/blade-iconpark": "^1.5",
        "filament/forms": "^2.0",
        "filament/tables": "^2.0",
        "guzzlehttp/guzzle": "^7.8",
        "laravel/framework": "^9.19",
        "laravel/jetstream": "^2.12",
        "laravel/sanctum": "^3.0",
        "laravel/scout": "^9.5",
        "laravel/tinker": "^2.7",
        "league/flysystem-aws-s3-v3": "^3.0",
        "league/flysystem-ftp": "^3.0",
        "livewire/livewire": "^2.5",
        "maatwebsite/excel": "^3.1",
        "power-components/livewire-powergrid": "^3.6",
        "sentry/sentry-laravel": "^3.1",
        "spatie/laravel-backup": "^8.1",
        "spatie/laravel-comments": "^1.4",
        "spatie/laravel-comments-livewire": "^1.2",
        "staudenmeir/laravel-adjacency-list": "^1.0",
        "te7a-houdini/laravel-trix": "^2.0",
        "teamtnt/laravel-scout-tntsearch-driver": "^12.1",
        "wire-elements/modal": "^1.0"
    },
    "require-dev": {
        "barryvdh/laravel-debugbar": "^3.7",
        "fakerphp/faker": "^1.9.1",
        "laravel/pint": "^1.0",
        "laravel/sail": "^1.0.1",
        "mockery/mockery": "^1.4.4",
        "nunomaduro/collision": "^6.1",
        "phpunit/phpunit": "^9.5.10",
        "spatie/laravel-ignition": "^1.0"
    },```
jszobody commented 11 months ago

Strange. Your initial message that maennchen/zipstream-php is already fixed in your lockfile to version 3.1.0.

I have this package running in Laravel 9 in multiple apps successfully. There's just some issue with your composer.lock file that you'll need to sort out. Try running with the -W flag to update all dependencies.

Make sure you're installing ^4.0 of this package as well.

kletellier commented 11 months ago

same issue for me, i've previously added package for aws s3, remove composer.lock and vendor folder and running composer update works fine

drjdr commented 10 months ago

@jszobody There is a new package available for maennchen/zipstream-php with version 3.1. A few packages like spatie/media-library v11 have this as a dependency. The current master of this project has a composer requirement for maennchen/zipstream-php to ^v2.0. Simply changing this to ^v2.0|^v3.1 is not an option, since the api has changed a lot. E.g. The class ZipStream\Option\Archive has been replaced in favor of named arguments in the ZipStream\ZipStream constuctor.

Since named arguments have a php 8.0+ requirement, I would suggest a major version update for this package, when including support for maennchen/zipstream-php to ^v3.1.

younus93 commented 10 months ago

Any suggestion on how to make this package work?

goszowski commented 10 months ago

stechstudio/laravel-zipstream[1.0, ..., 1.7, 2.0, ..., 2.6.1, 3.0] require php ^7.1 -> your php version (8.3.2)

jszobody commented 10 months ago

@goszowski The latest version of this package is 4.x, and supports PHP 8.x.

@younus93 Try removing the package and installing fresh, instead of upgrading. I have this package running successfully in Laravel 10 with PHP 8.3 apps.

@drjdr Yes I'm aware. maennchen/zipstream-php v3 was a major rewrite, requiring a pretty big rewrite of this package as well. It's on my list of things to work on, haven't been able to release it yet.

jszobody commented 4 months ago

@drjdr In case you haven't noticed, version 5 of this package was recently released based on maennchen/zipstream-php v3.1.