[One (M8) Q&A, Help & Troubleshooting] Salar.m:
Actually I can't neither flash twrp.zip nor boot twrp.zip file, As you see I've tried different twrp versions but it keeps erroring:

C:\adb>fastboot flash recovery twrp.img

target reported max download size of 1826332672 bytes

sending 'recovery' (20166 KB)...

OKAY [ 2.209s]

writing 'recovery'...

FAILED (remote: image update error)

finished. total time: 12.359s

C:\adb>fastboot boot recovery twrp.img

cannot load 'recovery': No such file or directory

C:\adb>fastboot boot recovery twrp.zip

cannot load 'recovery': No such file or directory

C:\adb>fastboot flash recovery twrp.img

target reported max download size of 1826332672 bytes

sending 'recovery' (20304 KB)...

OKAY [ 2.477s]

writing 'recovery'...

FAILED (remote: image update error)

finished. total time: 12.599s

it seems that you're right and some partitions are missing, I don't know why? some one else also issued this problem in ARHD M8 topic but no one answered him,

OK, I'll try to flash signed firmware.zip, But as I'm noob :D and don't want to brake my device too, please double check steps with me and see if I'm doing things in a right manner:

I should find my firmware.zip file from this post: (based on my CID which is BS_US001)

https://xdaforums.com/showpost.php?p=60218734&postcount=5

then I have to follow the steps mentioned in that post (as it says by locking again all internal storage files will be deleted, I know, But I have no alternative :D)

and after that what should I do? try to unlock again via fastboot command? install twrp.img again? and see if I can bring back device to TWRP recovery menu and see if Custom Roms and bring life to my device?

or shall I install RUU.zip file specifically designed for BS_US001 device via FASTBOOT command? (as BS_US001 devices are all Developer Edition, I chose last ROM for M8 from this official HTC link under "Unlocked/Developer" category:

https://www.htc.com/us/support/rom-downloads.html

am I doing steps correctly?

---------- Post added at 09:21 PM ---------- Previous post was at 08:40 PM ----------

Unfortunately I wasn't able to lock bootloader; I did it twice but the same errors come again: :confused::(

C:\adb>fastboot oem lock

...

(bootloader) [PGFS] partition_update_pgfs: pg1fs_security

(bootloader) Error: Command never completed

(bootloader) Error: Command timeout error

(bootloader) Error: Command completed with errors

(bootloader) Failed Reading block @ 2082

(bootloader) [SD_ERR] sd_read_sector: read sector failed (2082 2)

(bootloader) [PG_ERROR] htc_pg_hdr_get(118):

(bootloader) sd_read_sector error

(bootloader) [PG_ERROR] htc_pg_part_hdr_get(170):

(bootloader) htc_pg_hdr_get failed

(bootloader) TZ_HTC_SVC_ENC ret = 0

(bootloader) [PGFS] partition_update_pgfs: pg2fs_sec_recovery

(bootloader) Error: Command never completed

(bootloader) Error: Command timeout error

(bootloader) Error: Command completed with errors

(bootloader) Failed Reading block @ 262656

(bootloader) [SD_ERR] sd_read_sector: read sector failed (262656 2)

(bootloader) [PG_ERROR] htc_pg_hdr_get(118):

(bootloader) sd_read_sector error

(bootloader) [PG_ERROR] htc_pg_part_hdr_get(170):

(bootloader) htc_pg_hdr_get failed

(bootloader) Update pg2fs_sec_recovery fail (-1)

(bootloader) Lock successfully...

(bootloader) deinit_lcd

(bootloader) mipi display off

(bootloader) mdp_clock_off

(bootloader) disable_mmss_clk done

(bootloader) pll1_disable done

(bootloader) TZ_HTC_SVC_DISABLE ret = -1610744452 (0x9FFDFD7C)

(bootloader) [CRITICAL] SPMI write command failure: cmd_id =

0, error

(bootloader) = 4

(bootloader) [CRITICAL] SPMI write command failure: cmd_id =

0, error

(bootloader) = 4

(bootloader) [ERR] Cannot halt SPMI arbiter!!

(bootloader) [INFO] Rebooting device

FAILED (status read failed (No such file or directory))

finished. total time: 11.794s