No uploads have been allowed on LiveView

I recently upgraded my LiveView + Surface app to the latest and greatest, and after testing around, I realized that my live uploads had stopped working.

I have a LiveComponent that calls allow_upload/3 in its update/2, and it has a form with a <.live_file_input>. For some reason, though, that’s started to fail with ** (ArgumentError) no uploads have been allowed on LiveView–it seems to be sending the upload up to the LiveView instead of the LiveComponent? This definitely used to work, but I can’t figure out how to route that upload to the right place.

The form itself, when no uploads are involved, works just fine and routes its events to the correct component, too. This seems to be limited to <.live_file_input />.

Am I doing something wrong? Did something change recently that might’ve caused this?

Hi @zkat welcome to Elixir forum :tada:

Maybe this would be useful to debug the problem on your side.

I must’ve done the phx-target={@myself} thing wrong previously, because I could’ve sworn I’d done it, but I gave it another shot and it’s working now? Ah well. Thanks again :slight_smile: