Skip to content

Firebase storage uploadTask snapshots not progressing #4158

@jamesdaniels

Description

@jamesdaniels

It appears there's a bug with the way the new Compat delegates are setup in storage, a good reproduction is to cancel an upload and then check the snapshot state.

task.snapshot.state still equals running, whereas task._delegate.snapshot.state appropriately reads canceled.

You can see this on success too. I noticed this while debugging AngularFire/RxFire issues that users were reporting, while I worked around this by using the promise for now developers won't be able to takeWhile(snap => snap.state === 'running') etc. to catch errors, leading to broken observables and general mayhem in their apps.

Attached some screenshots of states seen in my console.logs. Note the conflict between the _delegate and the compat states.

Screen Shot 2020-12-03 at 4 44 39 PM

Screen Shot 2020-12-03 at 4 44 26 PM

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions