[Galaxy S 4 i9505 Original Android Development] invisiblek:
Here's the deal, I'm 99% sure its NOT properly flashing the rom. Removing the format will allow it to get past that, but it still won't write to the /system partition

Here's a clip of dmesg on a recovery boot that failed to flash a rom:

<3>[ 5.679412] As EXT4-fs error, printing data in hex
<3>[ 5.679412] [partition info] s_id : mmcblk0p16, start block# : 225864
<3>[ 5.679595] dump block# : 1, start offset(byte) : 0, length(byte) : 1024
<3>[ 5.679656] -------------------------------------------------
<3>[ 5.679809] 0x0000 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.679870] 0x0010 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680023] 0x0020 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680145] 0x0030 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680267] 0x0040 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680358] 0x0050 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680480] 0x0060 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680603] 0x0070 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680694] 0x0080 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680816] 0x0090 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.680969] 0x00a0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681091] 0x00b0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681182] 0x00c0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681304] 0x00d0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681427] 0x00e0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681518] 0x00f0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681640] 0x0100 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681793] 0x0110 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.681915] 0x0120 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682006] 0x0130 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682128] 0x0140 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682250] 0x0150 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682342] 0x0160 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682464] 0x0170 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682586] 0x0180 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682739] 0x0190 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682800] 0x01a0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.682952] 0x01b0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683074] 0x01c0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683166] 0x01d0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683319] 0x01e0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683441] 0x01f0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683593] 0x0200 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683654] 0x0210 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683807] 0x0220 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.683929] 0x0230 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684051] 0x0240 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684143] 0x0250 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684265] 0x0260 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684417] 0x0270 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684478] 0x0280 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684631] 0x0290 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684753] 0x02a0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684875] 0x02b0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.684967] 0x02c0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685089] 0x02d0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685241] 0x02e0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685302] 0x02f0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685424] 0x0300 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685577] 0x0310 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685699] 0x0320 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685791] 0x0330 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.685913] 0x0340 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686035] 0x0350 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686126] 0x0360 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686248] 0x0370 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686401] 0x0380 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686523] 0x0390 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686614] 0x03a0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686737] 0x03b0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686859] 0x03c0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.686950] 0x03d0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.687072] 0x03e0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.687225] 0x03f0 : 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................
<3>[ 5.687347] ---------------------------------------------------
<3>[ 5.687408] EXT4-fs (mmcblk0p16): VFS: Can't find ext4 filesystem

Not finding the ext4 filesystem is a pretty good indicator that it won't be able to write to it