#miaina_code

1 messages ¡ Page 1 of 1 (latest)

latent nebulaBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1278714219159879764

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

elfin bluff
#

Hello

#

Can you tell me more about exactly what you are trying to do here?

#

And can you share your code snippet that is triggering this error?

crimson igloo
#

Hello thank you for you time

#

Well We're using Stripe-php library

#

with PHP 8.2 application

#

and this error message is triggered every time now

elfin bluff
#

Sure but where is that error coming from

#

I need way more details to be able to help you

crimson igloo
#

We have a Symfony 6.4 project

#

with PHP 8.2 and the library use a dynamic attribute

elfin bluff
#

Have you added logs to your code to figure out where specifically that error is coming from?

crimson igloo
#

which is deprecated by php

#

We noticed the problem when we installed the stripe-php library

#

within our project

#

(in production we don't use php 8.2 nor the last version of stripe-php library) so we don't have the problem

elfin bluff
#

I can't help you much with this -- if you want to use newer versions of PHP / our SDK then you need to make sure your code is compatible

#

The first thing to do is track down what in your code is triggering that error on newer versions of PHP

crimson igloo
#

yes

#

Stripe/Collection is not compatible with php 8.2

#

that's what I'm telling you

elfin bluff
#

That is not true

crimson igloo
#

We did patch it

#

to make it work

elfin bluff
#

Right so you did custom things

crimson igloo
#

No

elfin bluff
#

Our SDK is compatible with the corresponding versions of PHP

#

As we note in our Changelog

#

It is likely the case that your code is based on an old version of PHP which after upgrading our SDK it is no longer compatible

#

So you have to ensure that you update your code as well if you want to update the Stripe PHP SDK version

crimson igloo
#

no

#

our code is in full php 8.2

#

and php 8.2 did deprecat the dynamic attribute

#

there's a dynamic attribute and Stripe/Collection class

#

as I mention in my request

#

$_requestParams;

#

for the moment to make it work we did add " protected $_requestParams;" in Stripe/Collection

elfin bluff
#

Okay let's pause.

#

You are saying there is a bug in the newest version of the Stripe PHP SDK when using PHP 8.2, correct?

#

Specifically version 15.7.0 of the Stripe PHP SDK

crimson igloo
#

yes

#

I would not say bug

#

i would say that for PHP 8.2 or newer version

#

it will not work

elfin bluff
#

Okay, what is a minimal code sample that will reproduce the error that you are seeing?

latent nebulaBOT
crimson igloo
#

Well I'm using a framework (symfony 6.4) with stripe-php. So It crashes during the init. I guess just a simple script with the stripe library will be sufficient. may be a code which use Stripe/Collection

elfin bluff
#

Yeah sorry that isn't going to do it -- I need something much more specific. We have many users that use PHP 8.2 with new versions of our SDK and we have not heard of this error before. Without a specific repro I can't help you here. If you want, I'd recommend either posting an issue on the stripe-php Github repo with full details or writing into our Support team via https://support.stripe.com/contact/login with full details and a way to reproduce the error.