D.C. Council members gave Lewis D. Ferebee on Tuesday a window into the political minefield that could await him if he is confirmed as the next chancellor of the District’s public school system.

At the final hearing before the council votes on Ferebee’s fate, council members asked him to address the disparate needs of their wards. They asked him to be honest about the District’s challenges — even if that means going against his boss, the mayor. They also asked him to survive in the District longer than his predecessor, who was forced out amid scandal after a year.

“As much as I hate politics in education, the past year has shown us that there are many people with immense knowledge in schools and education systems who are no longer in education in this city because they could not get the politics right,” said David Grosso (I-At Large), chair of the education committee. “I do not want to be in this situation a year or two from now because of political unforced errors. Our youth deserve better.”

When Ferebee — the former superintendent of Indianapolis schools and the District’s acting chancellor since January — testified under oath, he pushed back against council members’ assertions that the Midwestern city did not make sufficient achievement gains during his tenure.

Council members cited declining standardized test results during the five years Ferebee presided over Indianapolis schools, with the drop especially pronounced among African American students. Ferebee said he measures students’ success by more than just test scores and said more students are taking SATs in Indianapolis and have hit benchmarks proving they have the skills to get jobs or attend college.

Before Ferebee addressed the council, more than 30 residents testified, providing feedback to council members about the nomination. Many urged the council to approve him, while others wondered whether Ferebee was the right person to bolster a neighborhood school system.

Ferebee sought to distance himself from the reputation he gained as a charter school advocate who weakened the teachers union in Indianapolis. He dismantled neighborhood high schools in Indiana’s capital city and turned over many of the lowest-performing elementary schools to charter operators even as those schools remained part of the traditional system.

The 44-year-old educator portrayed himself as a leader who would strengthen the District’s traditional public school system, which faces strong competition from the city’s robust charter sector. He said it is the school system’s job to intervene when a school is underperforming, but he stressed that intervention does not mean relinquishing those schools to charter operators. That intervention, he testified, could mean implementing teacher and leadership training programs on the campuses concerned.

“Philosophically, I believe that every family should have the right to a neighborhood school in their neighborhood,” he said.

Ferebee also addressed the controversy over his handling of a 2016 sexual abuse case involving a teacher and student. He is the defendant in three lawsuits stemming from that episode. “I want to be really clear here,” he said. “I take any allegations of abuse and neglect really seriously.”

The council’s questioning of Ferebee, which lasted more than three hours, spanned a range of topics. Ferebee said he understood the challenges facing him in the District and would address the achievement gap — which he said is more aptly described as an opportunity gap — between students from low-income and wealthier families.

He said the gap could be bridged by providing access to ­early-childhood education and through equitable distribution of resources. He stressed the importance of strong principals and said retaining teachers is a priority.

He said he believes in the benefits of bilingual education and wants high school students to have more exposure to careers and work experience during the academic year.

Ferebee acknowledged not always engaging the community effectively when making drastic changes in Indianapolis, and he pledged to do better here.

“We can only move at the speed of trust,” he said, repeating a mantra he has invoked frequently during his first weeks in the District.

In Indianapolis, Ferebee drew a backlash for closing three neighborhood high schools with dwindling enrollment. Council member Elissa Silverman (I-At Large) asked whether Ferebee would commit to keeping all schools open during his D.C. tenure.

Ferebee said he did not feel comfortable making that pledge.

“We do not know what our resources will be in the future,” he said. “We do not know what our utilization will be.”

Ferebee was nominated by Mayor Muriel E. Bowser (D) to lead D.C. Public Schools, and his appearance Tuesday before the council was his first. Bowser named Ferebee on Dec. 3 to be the next chancellor of a school system that has been without a permanent leader since February 2018.

If confirmed, Ferebee, who would earn $280,000 a year, would inherit a growing school system rocked by a year of scandals. His predecessor, Antwan Wilson, resigned after city leaders discovered that he skirted the city’s competitive school lottery placement system to transfer his daughter to a sought-after high school with a waiting list.

The speakers at Tuesday’s hearing — residents, teachers, students and parents — brought up concerns about Ferebee’s record similar to those aired in two public forums on his nomination in recent weeks.

“You are coming into this city with a reputation that precedes you,” said Frazier O’Leary, a retired D.C. teacher and the Ward 4 representative on the D.C. State Board of Education. “There are many who only know you from what they have read and are afraid that you will not be an advocate for our public schools. Only you can dispel these notions through your words and actions.”

Other residents said they have met with Ferebee since he became acting chancellor and appreciated his willingness to listen and learn about the system and urged the council to approve his nomination.

Still, residents and council members called on the chancellor to focus on bridging the achievement gap between white students and students of color.

The D.C. Council has not scheduled a vote on Ferebee’s nomination, although if it does not vote by April 9, the mayor’s pick will automatically be approved.