HBO's Silicon Valley TV series
TJ Miller who plays Erlich Bachman on Silicon Valley will exit the show at the end of season 4 HBO

Good news for Silicon Valley fans – HBO has decided to renew the show for another season.

Bad news for Silicon Valley fans – One of the key characters of the show will be flying the coop at the end of season 4.

TJ Miller, who plays the potty-mouthed, pot-smoking entrepreneur Erlich Backman will be exiting the series following the close of the current season. News of his departure came hours after HBO announced that it had renewed the Mike Judge and Alec Berg produced show for a fifth season.

"The producers of Silicon Valley and TJ Miller have mutually agreed that TJ will not return for season 5," the network said in a statement on 25 May (via THR). "In Erlich Bachman, TJ has brought to life an unforgettable character, and while his presence on the show will be missed, we appreciate his contribution and look forward to future collaborations."

Thomas Middleditch, Zach Woods, Kumail Nanjiani, Martin Starr, Josh Brener, Amanda Crew, Matt Ross, Jimmy O Yang and Suzanne Cryer will return to the show for the next season but we may have to simply wait to see if they bring someone in to fill in the big vacuum left by Miller.

Silicon Valley
Silicon Valley has been renewed for a fifth season on HBO Facebook

Following the announcement, the 35-year-old's co-star Nanjiani took to Twitter to comment on his departure. "Very sad to say bye to Erlich Bachman. @nottjmiller is the funniest guy I've ever met & thrilled to work w him for 4 yrs. Brothers forever," he wrote.

The reason behind Miller's leaving has not been revealed but it most probably has to do with his busy schedule. He launched The Gorburger Show on Comedy Central, and was most recently seen on the big screen opposite Jennifer Aniston and Jason Bateman in Office Christmas Party. He starred as bartender Jack Hammer in 2016's Deadpool and has lent his voice to the upcoming The Emoji Movie, which releases on 4 August in the UK.

He will also return to the Isle Of Berk, voicing Tuffnut Thorston, the fraternal twin of Ruffnut Thorston in the third installation of How To Train Your Dragon, which should hit theatres in 2019.