Tokyo, Oct. 17 -- Japan's ruling and opposition parties on Friday agreed to elect a new prime minister to replace Shigeru Ishiba on Oct. 21, local media reported.

The ruling Liberal Democratic Party (LDP) and the main opposition Constitutional Democratic Party of Japan agreed to hold the parliamentary vote to pick the successor to outgoing Ishiba on Oct. 21, the day when an extraordinary Diet session kicks off, Kyodo News reported.

The two parties also confirmed that the term of the upcoming Diet session will be 58 days, ending on Dec. 17.

Sanae Takaichi won the LDP presidential election on Oct. 4. For the leader of the ruling party to become the next prime minister, they must be appointed by the Diet, Japan's parliament.

Both houses of...