This is a nice problem. Here is what I know.

(Below, I refer to the Handbook. This is the **Handbook of Set Theory**, Foreman, Kanamori, eds., Springer, 2010.)

First of all, the consistency of the failure of diamond at a weakly compact cardinal seems open. Woodin has asked this explicitly, I do not know if the question itself is due to him. Of course, $\diamondsuit_\kappa$ holds if $\kappa$ is measurable, so the problem is delicate. In fact, measurability is an overkill, and it suffices that $\kappa$ is subtle. The notion of subtlety is due to Jensen and Kunen, and the fact that $\diamondsuit_\kappa$ holds for subtle cardinals is due to Kunen, see

Ronald B. Jensen, and Kenneth Kunen. *Some Combinatorial Properties of $L$ and $V$*, unpublished manuscript, 1969, currently available at Jensen's page.

The argument in the Jensen-Kunen paper actually shows that subtlety of $\kappa$ implies $\diamondsuit_\kappa(\mathsf{REG})$, where $\mathsf{REG}$ denotes the stationary set of regular cardinals below $\kappa$. On the other hand, Woodin showed that it is equiconsistent with the existence of a weakly compact cardinal that $\mathsf{GCH}$ holds, and there is a weakly compact $\kappa$ such that $\diamondsuit_\kappa(\mathsf{REG})$ fails.

I do not know of the precise date of this result, but it has been extended in a variety of ways. For example, for $m,n\ge 1$, we can replace weak compactness with $\Pi^m_n$-indescribability. This stronger result is due to Hauser, see

Kai Hauser. *Indescribable cardinals without diamonds*, Arch. Math. Logic, **31 (5)**, (1992), 373–383. MR1164732 (93b:03082).

Džamonja and Hamkins further extended this to strongly unfoldable cardinals, see

Mirna Džamonja, and Joel David Hamkins. *Diamond (on the regulars) can fail at any strongly unfoldable cardinal*, Ann. Pure Appl. Logic, **144 (1-3)**, (2006), 83–95. MR2279655 (2007m:03091).

(But, again, this is not $\lnot\diamondsuit_\kappa(\kappa)$.) Another extension is due to Hellsten, see

Alex Hellsten. *Diamonds on large cardinals*, Thesis (Ph.D.)–Helsingin Yliopisto (Finland). 2003. 72 pp.

In his thesis, Hellsten proves the consistency of the failure of what he calls weakly compact diamond. To define this principle, let $\kappa$ be weakly compact. Consider the normal ideal over $\kappa$ generated by the sets of the form $\{\alpha<\kappa\mid (V_\alpha,\in, U\cap V_\alpha)\models\lnot\phi\}$ where $U\subseteq V_\kappa$, $\phi$ is a $\Pi^1_1$-sentence, and $(V_\kappa,\in,U)\models\phi$. Call *reflective* those subsets of $\kappa$ that are positive with respect to this ideal. We say that weakly compact diamond holds at $\kappa$ iff $\kappa$ is weakly compact and there is a sequence $(A_\alpha\mid \alpha<\kappa)$ such that $A_\alpha\subseteq\alpha$ for all $\alpha$, and for any $A\subseteq\kappa$ we have that $\{\alpha\mid A_\alpha=A\cap\alpha\}$ is reflective. (This principle was studied independently by Sun and Shelah; Hauser's results also give the consistency of the existence of weakly compact cardinals where weakly compact diamond fails.)

On the other hand, it is consistent that diamond fails at an inaccessible, or a Mahlo, or even a greatly Mahlo cardinal.

By results of Jensen, if diamond fails at a Mahlo, then $0^\sharp$ exists, the reference is

Ronald B. Jensen. *Diamond at Mahlo cardinals*, handwritten notes, Oberwolfach, 1991.

(Martin Zeman may have a copy of these notes.) In the note, Jensen proves that $0^\sharp$ exists if there is a $\kappa$ Mahlo such that $\diamondsuit_\kappa(\mathrm{cof}(\omega_1))$ fails.

This indicates that the arguments must be of a different nature than the equiconsistencies mentioned above. The best current lower bound is due to Zeman, see

Martin Zeman. *$\diamondsuit$ at Mahlo cardinals*, J. Symbolic Logic, **65 (4)**, (2000), 1813–1822. MR1812181 (2002g:03107).

Martin proves that if there is a Mahlo cardinal $\kappa$, and a regular cardinal $\varepsilon$ such that $\omega_1<\varepsilon<\kappa$, and $\diamondsuit_\kappa(\mathrm{cof}(\varepsilon))$ fails, then either $0^\mathbf{P}$, zero-pistol, exists, or else (the core model $K$ exists, and) $o^K(\beta)\ge\varepsilon$ for stationarily many $\beta<\kappa$. For difficulties improving this result, see the remarks in

Martin Zeman. *Diamond, GCH and weak square*, Proc. Amer. Math. Soc., **138 (5)**, (2010), 1853–1859. MR2587470 (2011g:03114).

The consistency of the failure of diamond at an inaccessible, a Mahlo, or a greatly Mahlo cardinal is due to Woodin. I do not know how efficient the upper bounds he obtains are, they are strong versions of hypermeasurability, somewhat past the existence of a $\kappa$ with Mitchell order $o(\kappa)=\kappa^{++}$, so there is certainly room for improvement bewteen these bounds and Zeman's.

The argument uses Radin forcing. James Cummings has a nice write-up (from around 1995), that I'm sure he will give you a copy of, if you email him directly,

James Cummings. *Woodin's theorem on killing diamonds via Radin forcing*, unpublished notes, 1995.

The idea is to begin with an embedding whose associated Radin sequence is sufficiently large. Recall that given $j:V\to M$ elementary, with critical point $\kappa$, we can define the Radin sequence associated to $j$ by setting $u^j(0)=\kappa$, and for $\alpha>0$, $u^j(\alpha)=\{X\subseteq V_\kappa\mid u^j\upharpoonright \alpha\in j(X)\}$. The construction stops at the first $\alpha$ such that $u^j\upharpoonright\alpha\notin M\cap V_{j(\kappa)}$. For $\beta<\alpha$, these $u^j(\beta)$ are $\kappa$-complete non-principal ultrafilters on $V_\kappa$. We call $\alpha$ the length of $u$, $\mathrm{lh}(u)$.

I'll skip here the definition of the Radin forcing $\mathbb R_u$ associated to $u$, as it is somewhat technical. It is not the original version as in Radin's paper, since he assumes supercompactness. A good reference is Gitik's paper in the Handbook, or see Chapter 6 in the unpublished

James Cummings, and W. Hugh Woodin. **Generalised Prikry forcing**, draft of book in preparation, ca. 1995.

(This is the book I refer to in this answer.)

Woodin's result is that if $\mathrm{lh}(u^j)=\kappa^+$ and $2^\kappa=\kappa^{++}$, then $\mathbb R_u$ preserves the inaccessibility of $\kappa$ and forces the failure of $\diamondsuit_\kappa$. Stronger large cardinal properties are preserved, under stronger assumptions on the length of $u$, and the same argument gives failure of $\diamondsuit_\kappa$ in the extension: If $\mathrm{lh}(u)=(\kappa^+)^2$, then $\kappa$ is Mahlo after the forcing, and if $\mathrm{lh}(u)=(\kappa^+)^{\kappa^+}$, then $\kappa$ is still greatly-Mahlo.

Unfortunately, it is not known how to preserve weak compactness this way (the known bounds on the length are much worse, we do not know if $\mathrm{lh}(u)=2^\kappa$ is an upper bound, for example; what is known is that preservation happens before we reach the first repeat point). Anyway, the argument for the failure of diamond breaks down if the length is too long.

That being said, let me add that Hugh's result gives more than the failure of diamond: In fact, he shows that no candidate sequence in the extension can guess every subset of $\kappa$ from the ground model. (And, modulo the technicalities of Radin forcing, the argument is surprisingly short.)

You should contact James, as he will know for sure whether there are further developments on the problem for weak compactness, and whether there are improvements on the upper bounds on the known cases.