Section 1942.4 does something the rest of the habitability chapter does not: it removes the landlord's ability to ask for the money at all. Subdivision (a) says a landlord may not demand rent, collect rent, issue a notice of a rent increase, or issue a three-day notice to pay rent or quit, if four conditions all exist before the demand or notice. The dwelling substantially lacks a characteristic listed in § 1941.1 or violates Health and Safety Code § 17920.10, or has been declared substandard under § 17920.3 because conditions endanger life, limb, health, property, safety or welfare. A public officer responsible for enforcing housing law has inspected and notified the landlord in writing of the obligation to abate or repair. The conditions have gone unabated for 35 days beyond service of that notice, without good cause. And the conditions were not caused by the tenant in violation of § 1929 or § 1941.2.
The inspection requirement is the part people miss. This section is not triggered by the tenant's own complaint; it is triggered by a citation from a housing enforcement officer followed by 35 days of inaction. That is why calling code enforcement changes the legal position in a way that another letter to the landlord does not.
The consequences are set out in subdivision (b): actual damages plus special damages of not less than $100 and not more than $5,000, and reasonable attorney's fees and costs to the prevailing party. Subdivision (c) lets the court order the nuisance abated and the substandard conditions repaired, and keep jurisdiction to ensure compliance. Subdivision (d) says the tenant need not try any other remedy first, and subdivision (e) allows the claim in small claims court within its limit. Whether a particular citation and timeline satisfy subdivision (a) is a question of documents and dates, and worth checking with a lawyer or a tenant service.