になっていました

had become

→ に
phrase Rare #25,311
had become Often describes a state that had come about by a certain time. Its meaning can vary in set patterns, such as ことになっていました (“was supposed to”) or the honorific お〜になっていました.
JA: 彼はいつの間にか有名になっていました。
EN: Before I knew it, he had become famous.

ある日バイロンが目を覚ましてみたら有名人になっていました。

One day, Byron woke up to find that he had become famous.

すでに直したつもりになっていました。

I thought I had already fixed it.

大統領はその月にフランスを訪れることになっていました。

The president was scheduled to visit France that month.

そこはすぐ廊下になっていました。

It immediately opened onto a hallway.

トムさんは少しホームシックになっていました。

Tom was feeling a little homesick.

長い間、空き家になっていました。

It had been vacant for a long time.

ナンシーはその場所に来ることになっていましたが、来ませんでした。

Nancy was supposed to come to that place, but she didn’t.

どのくらい私をお待ちになっていましたか。

How long have you been waiting for me?