• Jonah Williams's avatar
    [flutter_tools] implement safe file copy with multiple fallbacks (#69000) · 2e54c4a8
    Jonah Williams authored
    The tool observes a large number of unhandled exceptions during the file copy portion of flutter create. it is difficult to tell whether the permission issue is caused by the source/destination, or whether it is due to a bug in dart:io.
    
    To work around this, implement a permission check for both the source and dest files. If either fails, the tool can exit with a more specific message.
    
    If these checks pass, then perform the actual copy. If the copy fails, fallback to manually copying the bytes
    2e54c4a8
error_handling_io.dart 21.8 KB