Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix deprecations #6

Closed
RobinHoutevelts opened this issue Mar 7, 2024 · 8 comments
Closed

Fix deprecations #6

RobinHoutevelts opened this issue Mar 7, 2024 · 8 comments
Assignees

Comments

@RobinHoutevelts
Copy link
Contributor

The drupal/upgrade_status module found some warnings.
Not all of them are important. But in this case there is also a found deprecation so I've created this issue.

Scan
Wieni Video
Scanned on Thu, 03/07/2024 - 10:35.

8 warnings found.

modules/contrib/wmvideo/rector.php:
┌──────────┬──────┬────────────────────────────────────────────────────────────┐
│  STATUS  │ LINE │                          MESSAGE                           │
├──────────┼──────┼────────────────────────────────────────────────────────────┤
│ Check    │ 11   │ Fetching deprecated class constant PATHS of class          │
│ manually │      │ Rector\Core\Configuration\Option: Use @see                 │
│          │      │ \Rector\Config\RectorConfig::paths() instead               │
│          │      │                                                            │
│ Check    │ 15   │ Fetching deprecated class constant AUTOLOAD_PATHS of class │
│ manually │      │ Rector\Core\Configuration\Option: Use @see                 │
│          │      │ \Rector\Config\RectorConfig::autoloadPaths() instead       │
│          │      │                                                            │
└──────────┴──────┴────────────────────────────────────────────────────────────┘

modules/contrib/wmvideo/src/Plugin/Field/FieldWidget/VideoEmbedWidget.php:
┌──────────┬──────┬───────────────────────────────────────────────────┐
│  STATUS  │ LINE │                      MESSAGE                      │
├──────────┼──────┼───────────────────────────────────────────────────┤
│ Check    │ 37   │ Construct empty() is not allowed. Use more strict │
│ manually │      │ comparison.                                       │
│          │      │                                                   │
└──────────┴──────┴───────────────────────────────────────────────────┘

modules/contrib/wmvideo/src/Plugin/Validation/Constraint/VideoValidator.php:
┌──────────┬──────┬────────────────────────────────────────────────────┐
│  STATUS  │ LINE │                      MESSAGE                       │
├──────────┼──────┼────────────────────────────────────────────────────┤
│ Check    │ 29   │ Foreach overwrites $value with its value variable. │
│ manually │      │                                                    │
└──────────┴──────┴────────────────────────────────────────────────────┘

modules/contrib/wmvideo/src/Service/VideoInfo.php:
┌──────────┬──────┬───────────────────────────────────────────────────────────┐
│  STATUS  │ LINE │                          MESSAGE                          │
├──────────┼──────┼───────────────────────────────────────────────────────────┤
│ Check    │ 34   │ Construct empty() is not allowed. Use more strict         │
│ manually │      │ comparison.                                               │
│          │      │                                                           │
│ Check    │ 49   │ Call to deprecated function GuzzleHttp\json_decode():     │
│ manually │      │ json_decode will be removed in guzzlehttp/guzzle:8.0. Use │
│          │      │ Utils::jsonDecode instead.                                │
│          │      │                                                           │
└──────────┴──────┴───────────────────────────────────────────────────────────┘

modules/contrib/wmvideo/wmvideo.info.yml:
┌──────────┬──────┬────────────────────────────────────────────────────────────┐
│  STATUS  │ LINE │                          MESSAGE                           │
├──────────┼──────┼────────────────────────────────────────────────────────────┤
│ Check    │ 0    │ Value of core_version_requirement: ^9.3 || ^10 is not      │
│ manually │      │ compatible with the next major version of Drupal core. See │
│          │      │ https://drupal.org/node/3070687.                           │
│          │      │                                                            │
└──────────┴──────┴────────────────────────────────────────────────────────────┘

modules/contrib/wmvideo/composer.json:
┌──────────┬──────┬──────────────────────────────────────────────────────────────┐
│  STATUS  │ LINE │                           MESSAGE                            │
├──────────┼──────┼──────────────────────────────────────────────────────────────┤
│ Check    │ 0    │ The drupal/core requirement is not compatible with the next  │
│ manually │      │ major version of Drupal. Either remove it or update it to be │
│          │      │ compatible. See                                              │
│          │      │ https://drupal.org/node/2514612#s-drupal-9-compatibility.    │
│          │      │                                                              │
└──────────┴──────┴──────────────────────────────────────────────────────────────┘
@RobinHoutevelts RobinHoutevelts changed the title Upgrade_status scan found warning Fix deprecations Mar 7, 2024
benjamintoussaint added a commit that referenced this issue Mar 12, 2024
benjamintoussaint added a commit that referenced this issue Mar 14, 2024
@RobinHoutevelts
Copy link
Contributor Author

The commit that adds \Drupal\Core\Utility\Error::logException() is only present in Drupal >=10.1.
I think we need to update composer.json to make it clear this module is only compatible with "drupal/core": "^10.1".

@benjamintoussaint can you create a new release with this change?
And I also propose we remove the current tag both in GitHub and Packagist.

Sorry I didn't spot this sooner 🙏

benjamintoussaint added a commit that referenced this issue Mar 16, 2024
The commit `5a797eae17befff34e641f96e04938bd05523eba ` that adds `\Drupal\Core\Utility\Error::logException()` is only present in Drupal `>=10.1`.
benjamintoussaint added a commit that referenced this issue Mar 16, 2024
@benjamintoussaint
Copy link
Contributor

@RobinHoutevelts I should have checked that, thanks!

#9

@benjamintoussaint
Copy link
Contributor

@RobinHoutevelts Should I maybe add info about deprecations fix in newest tag, prior to delete the previous one? (merge)
https://github.com/wieni/wmvideo/releases

@RobinHoutevelts
Copy link
Contributor Author

@benjamintoussaint yeah that sounds good.
So the Full Changelog url changes to 1.3.0...1.3.2 right?

benjamintoussaint added a commit that referenced this issue Mar 19, 2024
We first released `1.3.1` without a fix of Drupal version requirement, fix that we did in `1.3.2`, so now we will delete both `1.3.1` and `1.3.2` and release a new `1.3.1`.
benjamintoussaint added a commit that referenced this issue Mar 19, 2024
We first released `1.3.1` without a fix of Drupal version requirement, fix that we did in `1.3.2`, so now we will delete both `1.3.1` and `1.3.2` and release a new `1.3.1`.
@benjamintoussaint
Copy link
Contributor

@RobinHoutevelts You're right!

I'm guessing I'll need you to remove tags from GitHub:

Screenshot

Delete tag nope@2x

I was able to delete them on Packagist though.

@RobinHoutevelts
Copy link
Contributor Author

@benjamintoussaint I think you have to delete the associated releases first and then you can delete the tags.
Can you try it? (Just to make sure it's not a permission thing for future reference).

@benjamintoussaint
Copy link
Contributor

@RobinHoutevelts You were right, thanks 🙏

@benjamintoussaint
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants