<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>211234</bug_id>
          
          <creation_ts>2020-04-30 07:38:13 -0700</creation_ts>
          <short_desc>[iOS] Revoking an object URL immediately after triggering download breaks file download</short_desc>
          <delta_ts>2021-01-20 22:49:18 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebKit Misc.</component>
          <version>Safari 13</version>
          <rep_platform>iPhone / iPad</rep_platform>
          <op_sys>iOS 13</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>212279</dup_id>
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=185531</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Henning Stummer">henning</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>Andy_Schmidt</cc>
    
    <cc>cdumez</cc>
    
    <cc>david_quesada</cc>
    
    <cc>felek.000</cc>
    
    <cc>henning</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1647365</commentid>
    <comment_count>0</comment_count>
      <attachid>398053</attachid>
    <who name="Henning Stummer">henning</who>
    <bug_when>2020-04-30 07:38:13 -0700</bug_when>
    <thetext>Created attachment 398053
File with a test download

Load the attached file in Safari on iOS:

When you click on &quot;Download&quot; you get an error page with the following text:
&quot;The operation couldn&apos;t be completed. (WebkitBlobResource error 1.)&quot;

When you add a timeout before revoking the objectURL, the download start, but the &quot;download&quot; attribute is ignored. The file will get the filename &quot;unknown&quot; instead.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1647908</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2020-05-01 10:37:22 -0700</bug_when>
    <thetext>&lt;rdar://problem/62735862&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1655392</commentid>
    <comment_count>2</comment_count>
    <who name="Chris Dumez">cdumez</who>
    <bug_when>2020-05-22 12:25:40 -0700</bug_when>
    <thetext>(In reply to Henning Stummer from comment #0)
&gt; Created attachment 398053 [details]
&gt; File with a test download
&gt; 
&gt; Load the attached file in Safari on iOS:
&gt; 
&gt; When you click on &quot;Download&quot; you get an error page with the following text:
&gt; &quot;The operation couldn&apos;t be completed. (WebkitBlobResource error 1.)&quot;

Bug 185531 was the fix for this and it seems to be working fine on macOS. However, it indeed does not seem to work as expected on iPadOS with your example for some reason.

&gt; When you add a timeout before revoking the objectURL, the download start,
&gt; but the &quot;download&quot; attribute is ignored. The file will get the filename
&gt; &quot;unknown&quot; instead.

I was not able to reproduce this but I am on a beta build. It may have been fixed or it is flaky because of 100ms timer.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1655438</commentid>
    <comment_count>3</comment_count>
    <who name="Chris Dumez">cdumez</who>
    <bug_when>2020-05-22 14:24:13 -0700</bug_when>
    <thetext>I have verified that fixing Bug 212279 fixes this too.

*** This bug has been marked as a duplicate of bug 212279 ***</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>398053</attachid>
            <date>2020-04-30 07:38:13 -0700</date>
            <delta_ts>2020-04-30 07:38:13 -0700</delta_ts>
            <desc>File with a test download</desc>
            <filename>download-blob.html</filename>
            <type>text/html</type>
            <size>867</size>
            <attacher name="Henning Stummer">henning</attacher>
            
              <data encoding="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