WASHINGTON — A judge has ruled the Metropolitan Police Department must begin to comply with the NEAR Act, a law passed three years ago requiring police officers to record the race of every person they stop. 

"It's been a long three years in which D.C. police have for a long time failed to do anything about the data collection requirement," said Scott Michelman, legal co-director for the American Civil Liberties Union of D.C.

The Superior Court of D.C.'s ruling came after a number of advocacy groups-- including D.C.'s American Civil Liberties Union-- sued the city, claiming officers were not properly collecting that mandated racial data. 

RELATED: ACLU DC says police response to stop and frisk request 'absurd'

"We’re a little perplexed because we tend to be in full compliance with the data collection," said Police Chief Peter Newsham at a press conference on Friday. 

"For anyone who thinks that the court ruling is something that changed anything that's happened here, it's not. I think the court was well aware that we were gonna have all the systems in place this summer. We believe that we will have all the systems in place to collect this data in July. So I think that the ruling is not going to be very impactful to us," Newsham told WUSA9. 

Newsham added police had been planning to implement a new data collection system by the summer anyway, and that in the meantime, his department had been complying with the law by recording all traffic stops on body cameras

RELATED: 'I don't know where to begin' | Commanders criticize DC police officer's invasive search of man

"[The judge] was uncomfortable with that interim solution, so that's where much of his criticism came from. We disagree on that," said Newsham. 

The court wants police to do more, ordering police to now use the form below at every stop. Officers will be required to very clearly indicate things like the subject's ethnicity, the reason for the search, and the result of the stop. 

The ACLU says the ruling is crucial, as collecting this information is the only way to know if police are targeting certain demographics.

"We've been hearing for years members of the community tell us in deeply personal and moving terms about how they are being over-policed, racially profiled, and generally harassed by the officers that are supposed to protect and serve them," said Michelman. 

RELATED: DC residents still search for answers after MPD 'stop and frisk' of three boys

"This data will enable us to see if  something systemic is going on and that’s the first step to reform," said Michelman. 

Police have until July 25th to comply and begin collecting this racial data. If they don't, the ACLU says it will file a motion of contempt, which could result in financial penalties for the police. 

In March 2016, the District of Columbia enacted the Neighborhood Engagement Achieves Results (NEAR) Act of 2016. One of its key provisions required the D.C. Metropolitan Police Department (MPD) to collect detailed and comprehensive data about stops and frisks the police carry out on the streets of the District.