final-form / react-final-form

🏁 High performance subscription-based form state management for React
https://final-form.org/react
MIT License
7.39k stars 481 forks source link

change is not a function #1026

Open FC-jan opened 1 year ago

FC-jan commented 1 year ago

Are you submitting a bug report or a feature request?

bug report

What is the current behavior?

We received a bugsnag alert about state.change not being a function: TypeError P.change is not a function

Meanwhile, we at least introduced source maps, so the code mentioned points me to:

Screenshot 2023-03-10 at 15 23 32

What is the expected behavior?

change should be a function and should only be called if it's a function.

Sandbox Link

Sadly, I again have no idea how our end users produce the exception.

What's your environment?

"final-form": "4.20.7",
"react": "^17.0.2",
"react-final-form": "^6.5.9",

Current chrome, node 18

Other information

Sorry for again not being able to provide more info - I reported a similar, but different issue in final-form.

FC-jan commented 1 year ago

minor update: might be related to our usage of final-form-arrays. we also had other issues probably related to that, see also https://github.com/final-form/final-form/issues/472. as stated there, I was provided with some angles, and will still try to reproduce the issue - but this might also be it for now, as we seem to have worked around the issue.