Weird license inactive (wrong status compared to online dashboard)
Bug description
Can't say why but even if expire date is about 6 months from now, it's says inactive:

Of course I manually masked the license codes. Also soft-related to #321.
To reproduce
Steps to reproduce the behavior:
- Who knows. :) Maybe some network issues the last time it tried to update license data?
Expected behavior
Licenses should be shown as active.
Environment
- PHP: 7.4
- WordPress: 5.6.1
- Notification plugin: 7.2.2
@mircobabini the network issue seems to be the potential reason! I'm wondering why the status is inactive though.
I checked your license history - did the recent deactivating and activating helped?
Well, since it's on a production website, I can't just deactivate and reactivate.
By the way this is my report:
- After a week the issue was still there (weird since you set the transient expire time in 24h);
- I added
define( 'NOTIFICATION_DEBUG', true ), double CTRL+R and it's gone.
Let's see; if the error persists, I'll receive a notice with some more details about it.
error_log( print_r( $response, true ) );
I'll keep you posted.
I think found it! The extensions are info about validation is cached for 24h, yes, but the License itself is not expiring at all. I'll take a closer look.
PS. License deactivation won't do anything so you can safely do that :)
I couldn't track down this issue but noticed EDD Software Licensing plugin we are using to handle licenses has released a fix for inconsistent responses from the API. Hopefully, it will resolve this issue but let's keep this ticket open.
I had this one once again today. Fixed the same way (deactivated and reactivated the license).
Thanks for the update! Was anything caught in the log?
Yeah... no XD that debug line was not in place anymore. My fault.
Just restored, let's see next time.
Ohhh that's a shame :) but it happens. On my end no more findings regarding that and no one else reported that issue
Another customer just reported very similar issue so it seems to be an edge case probably with cached check
I've just one site where I still face the issue and I was able to define a pattern.
It's about connections dropped at a certain point, almost random. I was able to see that without Kaspersky active on the server, the issue disappear.
Then I've tried to see how to modify the WordPress's cURL transport and I've found that removing these lines the issue disappear:
https://github.com/WordPress/WordPress/blob/18d741be3762cf33c8ccdbcc066b6048275288a1/wp-includes/Requests/Transport/Curl.php#L365-L368
I think I should make a PR to add the "Connection: close" header only for cURL version < 7.22.
It will probably take forever to be merged into core, but... :D
Oh wow, that's some solid research! And the very peculiar issue 🤔
Let's see how it goes. https://core.trac.wordpress.org/ticket/54588