ash-jc-allen / short-url

A Laravel package for creating shortened URLs for your web apps.
MIT License
1.27k stars 162 forks source link

Laravel Jetstream compatability issue due to jenssegers/agent outdated dependency #227

Closed Cyborgmatt closed 6 months ago

Cyborgmatt commented 11 months ago

Laravel's Jetstream contributors have reworked the code base to avoid relying on the jenssegers/agent package that doesn't get maintained any more and instead uses the latest mobiledetect/mobiledetectlib.

Ref: https://github.com/laravel/jetstream/pull/1399 & https://github.com/laravel/jetstream/pull/1412

As a result, this package is no longer compatible with the latest version of Laravel Jetstream due to dependency clashes:


    - jenssegers/agent[v2.6.0, ..., v2.6.4] require mobiledetect/mobiledetectlib ^2.7.6 -> found mobiledetect/mobiledetectlib[2.7.6, ..., 2.8.45] but the package is fixed to 4.8.04 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
    - ashallendesign/short-url v7.8.0 requires jenssegers/agent ^2.6 -> satisfiable by jenssegers/agent[v2.6.0, ..., v2.6.4].
    - Root composer.json requires ashallendesign/short-url ^7.8.0 -> satisfiable by ashallendesign/short-url[v7.8.0].```
ash-jc-allen commented 11 months ago

Hey @Cyborgmatt! Sorry that you're having issues with the package.

I've tried to investigate this, but I can't seem to reproduce any kind of error from Composer. I've run:

laravel new example
cd example
composer require laravel/jetstream
composer require ashallendesign/short-url

This appears to work and installs Jetstream v3.2.5 and Short URL v7.8.0.

Do you have any steps to reproduce the error that I can follow, please? 🙂

ash-jc-allen commented 11 months ago

Actually, sorry, ignore my last comment. I've just realised that I had a slight error in the commands I run on my end and I do actually get the same error as you 🤦‍♂️

I'm not entirely sure how long it might be until I can work on a fix for this. But I'll try and work on something over my Christmas break. I'm definitely open to any suggestions or PRs though on the best way to tackle this 🙂

HannesEURESA commented 9 months ago

Hello, we have the same problem. Are here any updates at the moment? Greetings

ash-jc-allen commented 9 months ago

Hey @HannesEURESA!

Unfortunately, I've not really got any updates on this one, sorry.

I tried to take a quick look at this over Christmas and couldn't make a decision on the best way to tackle this. I have a feeling I might need some help with this one from the community on the best way to fix it 🙂

bdj-Razik commented 6 months ago

please any update for this issue

orcusmir commented 6 months ago

please any update for this issue

+1

ash-jc-allen commented 6 months ago

Hey everyone! Sorry for the delay on all this. Personal life has been pretty hectic, so I've not really had much spare time to really get stuck into this issue. I've only been able to jump on the quick pull requests that take a couple of minutes to check and review.

It looks like there are some open PRs that might be able to solve the issue. I'm just going to do some extra work to wrap the implementation behind a first-party class in the package (something like AshAllenDesign\ShortUrl\Classes\UserAgentHandler). This way, we can switch out the package behind the scenes in the future without any breaking changes, etc 🙂

ash-jc-allen commented 6 months ago

Hey everyone!

Just a quick update on this. I've just released Short URL v8.0 which now uses a different package for detecting the user tracking info. So this issue should hopefully be solved and Short URL should work with Laravel Jetstream! 😄

I'm going to make the assumption that this latest release will get you back up and running. So I'll close this issue. But if you're still having any issues, feel free to give me a shout and I'll take a look.

Huge thank you for your patience, and sorry for taking so long to put a fix together! Thanks 😄

Release notes: https://github.com/ash-jc-allen/short-url/releases/tag/v8.0.0