The 2024 PHB lore text for Warlocks and Clerics, fwiw.
Warlock
Warlocks quest for knowledge that lies hidden in the fabric of the multiverse. They often begin their search for magical power by delving into tomes of forbidden lore, dabbling in invocations meant to attract the power of extraplanar beings, or seeking places of power where the influence of these beings can be felt. In no time, each Warlock is drawn into a binding pact with a powerful patron. Drawing on the ancient knowledge of beings such as angels, archfey, demons, devils, hags, and alien entities of the Far Realm, Warlocks piece together arcane secrets to bolster their own power.
Warlocks view their patrons as resources, as means to the end of achieving magical power. Some Warlocks respect, revere, or even love their patrons; some serve their patrons grudgingly; and some seek to undermine their patrons even as they wield the power their patrons have given them.
Once a pact is made, a Warlock’s thirst for knowledge and power can’t be slaked with mere study. Most Warlocks spend their days pursuing greater power and deeper knowledge, which typically means some kind of adventure.
Warlock additionally has under the Pact Magic feature:
Level 1: Pact Magic
Through occult ceremony, you have formed a pact with a mysterious entity to gain magical powers. The entity is a voice in the shadows—its identity unclear—but its boon to you is concrete: the ability to cast spells.
I don't see a later feature (such as the Level 3 subclass selection) with lore text indicating
when the Warlock finds out who their patron is, just this early text that insists the Warlock doesn't know at Level 1. Presumably they know by Level 9, but the Level 9 feature also has some curious lore suggestions (such as that you
may have never talked to your patron directly before then)...
Warlock Level 3 subclass selection text
Level 3: Warlock Subclass
You gain a Warlock subclass of your choice. The Archfey Patron, Celestial Patron, Fiend Patron, and Great Old One Patron subclasses are detailed after this class’s description. A subclass is a specialization that grants you features at certain Warlock levels. For the rest of your career, you gain each of your subclass’s features that are of your Warlock level or lower.
Warlock Level 9 Contact Patron feature
In the past, you usually contacted your patron through intermediaries. Now you can communicate directly; you always have the Contact Other Plane spell prepared. With this feature, you can cast the spell without expending a spell slot to contact your patron, and you automatically succeed on the spell’s saving throw.
Once you cast the spell with this feature, you can’t do so in this way again until you finish a Long Rest.
Cleric
Clerics draw power from the realms of the gods and harness it to work miracles. Blessed by a deity, a pantheon, or another immortal entity, a Cleric can reach out to the divine magic of the Outer Planes—where gods dwell—and channel it to bolster people and battle foes.
Because their power is a divine gift, Clerics typically associate themselves with temples dedicated to the deity or other immortal force that unlocked their magic. Harnessing divine magic doesn’t rely on specific training, yet Clerics might learn prayers and rites that help them draw on power from the Outer Planes.
Not every member of a temple or shrine is a Cleric. Some priests are called to a simple life of temple service, carrying out their devotion through prayer and rituals, not through magic. Many mortals claim to speak for the gods, but few can marshal the power of those gods the way a Cleric can.
Clerics are safe from any lore mandate that demands they somehow don't know their god before Level 3.
Warlocks are almost safe- except for the Pact Magic description. For Warlocks there is also a suggestion that they commonly intentionally seek their patron ("they often begin their search for magical power..."). The Warlock players I know prefer
patron-by-accident or
patron-by-necessity (think Wyll in BG3) so the suggested route is irrelevant to them. The Warlock who
intentionally looks for a patron is going to be a very different kind of character.
The Playtest 5 UA for Warlock had more specific details and timeline for their acquisition of a patron, suggesting that their low-level powers are from "bargains from lesser entities", and that was rescinded in the final PHB.
The Warlock stuff is kind of stupid and is a good example of coming up with a mechanical property (subclass at Level 3) and then not giving enough thought to the lore explanation for it, especially given all the ways people play Warlocks. So if you feel you cannot do something the book does not endorse, then yes, this will annoy you.