A sentence that contains a compound subject but is treated as singular in meaning typically involves nouns or phrases that are connected by "and" but refer to a single entity or concept. One example of such a sentence is:
"Peanut butter and jelly is my favorite sandwich."
In this sentence, "peanut butter and jelly" is a compound subject (two items), but it refers to a single item (the sandwich) and is therefore treated as singular in meaning, taking the singular verb "is."