OAKLAND — Despite getting called to an illegal rave at the Ghost Ship warehouse — complete with $25 cover charge and sales of booze and drugs — an Oakland police officer in 2015 decided to break up the party but not cite the uncooperative promoter for code violations, according to newly released records.

Oakland officials, who had heavily censored police incident reports last week before releasing more than 600 pages of documents under threat of lawsuit by this newspaper, released those same records Tuesday with key passages now intact. The new information provided the clearest picture yet of the advance warning the city had of unsafe conditions and illegal activities at the warehouse before 36 people died there Dec. 2 in an inferno during a dance party.

At this newspaper’s request, other records that had previously been redacted were also released Tuesday, adding new details of a fight involving the art collective’s founder, Derick Almena, along with an arson investigation at the site, both in 2014.

Between mid-2014 and the deadly fire, police visited the building and associated properties nearly three dozen times, dealing with thefts, reports of child abuse, a stabbing, gun threats, drug sales, illegal housing and more.

But that isn’t the whole story. Police, fire, public works and building department employees had visited the Ghost Ship and other nearby properties at least 245 times since 1988, most of them after 2007. In response to questions as to why police officers did not notify code enforcement officers or cite Ghost Ship associates for reports of an illegal rave and illegal housing, city and police officials have insisted that it’s not a street cop’s duty to handle permit infractions. Other communities have joint efforts between police and code enforcement, and the mayor has said an upcoming software upgrade will increase such coordination.

Among the key police incident reports released Tuesday, the biggest revelation came from a March 1, 2015, encounter:

At 1:34 a.m., a 22-year-old woman flagged down Officer Hector Chavez to report an illegal rave with drug and alcohol sales. The woman told Chavez she went to the Ghost Ship for a private party with several friends, but when they arrived at the venue they were charged $25 at the door, according to Chavez’s report. She also told the officer that people were selling booze and a “wide variety of drugs,” including marijuana and Ecstasy, inside.

Chavez wrote that he observed people loitering outside, but when he drove up “all the subjects ran inside and closed the door behind them.” As loud music thumped from inside, he banged on the door, and although he could hear people inside, no one opened the door. Finally, rave promoter Sean Griffith, aka Hatter, came outside to speak to the officer, according to Chavez’s report.

Chavez wrote that it appeared Griffith was in violation of the city’s cabaret permit ordinance “since I know from previous contacts with Derick Almena (who rents the building) that this facility does not have a cabaret permit and is supposed to be an art studio.” Almena is the Ghost Ship founder who is under criminal investigation for his role in the deadly fire.

Chavez advised the promoter about a noise complaint earlier that night and the illegal rave allegations. Griffith, an Oakland resident, told him he did not have a license, but was hosting a private party.

“I advised Griffith that I knew that there was an illegal rave at the facility and that he had to shut it down,” Chavez wrote. He told Griffith he would wait for everyone to leave, but Griffith walked inside and tried to shut the door.

“I had my foot by the door and my leg was caught between the door and the door frame since they were trying to shut the door,” the officer wrote. “I had to push the door open to free my leg.”

As several dozen people left the warehouse, Griffith told the officer he had a private club called “Outlet” and members pay a monthly fee to attend his parties. Chavez said he left when Griffith told him that he and some other people had to stay to tear down lighting and sound equipment. He wrote that he did not cite Griffith for a cabaret permit violation, but did not give a reason. Attempts to reach Griffith on Tuesday were not successful.

Twenty minutes later, Almena called police to have “several subjects” removed from the warehouse for refusing to leave, and police again watched to ensure they left.

In September 2014, police responded to an early morning report of an arson just outside the warehouse where firefighters had seen and doused a burning sofa on the sidewalk, according to another now unredacted report.

“The business at this location has several pieces of furniture set outside as the employees regularly work throughout the night on their projects,” Officer Michael Erickson wrote in a report.

Almena told the officer that he awoke at about 6 a.m. and saw an “orange glow” outside a window. Firefighters were already there, he said. Sources have told this news organization that at least one firefighter that morning got a glimpse inside the warehouse, became alarmed at the conditions, and reported it to the department’s fire prevention division.

No action was ever taken.

In December 2014, the father of an artist living in the upstairs area of the warehouse and Almena got in a fight over rent, a newly unredacted report states.

Almena allegedly tackled the man, Max Schultz, and punched him in the back of the head, Officer Michael Camacho, one of five officers who responded, wrote in the report.

Both men demanded the other be arrested. Schultz told police he wouldn’t stay away from the Ghost Ship and said he “might be murdered if both parties stayed under one roof.”

Both men were arrested for battery, Camacho wrote. Almena was given a citation, but fearing more violence, officers took Schultz into custody.