So there was an exercise that I solved sometime ago which required me to prove that if $\kappa$ is ineffable, then $\{\nu \lt \kappa: \nu \text{ is weakly-compact}\}$ is stationary. At the time, I proved the stronger statement that: If $\kappa$ is ineffable, then so is $\{\nu \lt \kappa: \nu \text{ is weakly-compact}\}$. And now that I have been reviewing it, I found some flaws in it and managed to correct them. But since I haven't seen this statement elsewhere, my proof might be wrong again. So I would appreciate it if someone could point out any potential flaws.
First, let me give a definition: Let $X \subseteq \kappa$, we say that $X$ is ineffable iff for all sequences $\langle A_\alpha: \alpha\in X\rangle$ with $A_\alpha \subseteq \alpha$, there exists a stationary $S\subseteq X$ such that for any $\alpha, \beta \in S$ with $\alpha \lt \beta$, $A_\alpha = A_\beta \cap \alpha$.
So the argument goes like this: First note that the set of cardinals below $\kappa$ is ineffable. This follows from the fact that it forms a club. Now we show that the set of regular cardinals below $\kappa$ is ineffable. (This is the tricky part.)
First let $\langle A_\xi: \xi \text{ a regular cardinal}\rangle$ be a sequence such that $A_\xi \subseteq \xi$. Now we shall extend this sequence to all of cardinals below $\kappa$. First for any singular cardinal $\mu \lt \kappa$, let $C_\mu$ be a club of ordertype $\operatorname{cf}(\mu)$ below $\mu$. Now inductively construct $B_\mu$ for singular $\mu$ with $|B_\mu| \lt \mu$ in the following fashion:
If $\mu = \aleph_\omega$, then let $B_\mu = \emptyset$.
If $\mu \gt \aleph_\omega$ is singular, assume the induction hypothesis for singular cardinals below $\mu$. For each singular $\mu' \in C_\mu$, since $|B_{\mu'}| \lt \mu'$, choose some $\alpha \lt \mu'$ such that $\alpha \not \in B_{\mu'}$. Let $B_\mu$ be the set of the selected $\alpha$'s. Also since $|C_\mu| = \operatorname{cf}(\mu)$, we have $|B_\mu| \lt \mu$.
Now for singular $\mu$, let $A_\mu$ be a nice and definable coding of $\langle C_\mu, B_\mu \rangle$ as a subset of $\mu$. Now since $A_\xi$ is defined for all cardinals below $\kappa$, by ineffability, let $S \subseteq \kappa$ be a stationary subset of cardinals such that for all $\alpha,\beta \in S$ with $\alpha \lt \beta$, $A_\beta\cap\alpha = A_\alpha$. Now split $S$ into $S_0$ and $S_1$, such that $S_0$ is the set of all singulars in $S$ and $S_1$ is the set of regulars in $S$. It suffices to show that $S_0$ is non-stationary. We will show that $S_0$ can have at most $1$ element!
Suppose $\mu',\mu \in S_0$ with $\mu'\lt \mu$. Then $A_\mu\cap\mu' = A_{\mu'}$, so by the nice coding we have chosen, we have: $C_\mu\cap\mu' = C_{\mu'}$ and $B_\mu\cap\mu' = B_{\mu'}$. But this is contradictory, since by the fact that the $C_\lambda$'s are clubs, we have $\mu' \in C_\mu$ and therefore by construction there is some $\alpha \lt \mu'$ which is in $B_\mu$ but not in $B_{\mu'}$. A contradiction. So $S_0$ has at most one element and thus $S_1$ is stationary and so the set of regular cardinals below $\kappa$ is ineffable.
Now that we have the above, we know that the set of inaccessibles is ineffable, because $\kappa$ is Mahlo and so the set of strong limit cardinals is club in $\kappa$. And lastly to show that the set of weakly compact cardinals below $\kappa$ is ineffable, let $\langle A_\xi: \xi \text{ weakly compact}\rangle$ be a sequence such that $A_\xi \subseteq \xi$.
Extend this sequence to the set of inaccessibles below $\kappa$ as follows: for any $\lambda \lt \kappa$ such that $\lambda$ is inaccessible and is not weakly compact, let $A_\lambda$ uniformly code a $\lambda$-tree with no branches. So by the ineffability of $\{\lambda \lt \kappa: \lambda \text{ inaccessible}\}$, let $S \subseteq \kappa$ be a stationary subset of inaccessible cardinals below $\kappa$ such that for all $\alpha,\beta \in S$ with $\alpha \lt \beta$, $A_\beta\cap\alpha = A_\alpha$. Now split $S$ into $S_0$ and $S_1$, such that $S_0$ is the set of all non-weakly compacts in $S$ and $S_1$ is the set of weakly compacts in $S$. It suffices to show that $S_0$ is non-stationary. We will show that $S_0$ is bounded.
Suppose $S_0$ is unbounded below $\kappa$ and look at $A = \bigcup\{A_\alpha: \alpha \in S_0\}$. Since these $A_\alpha$'s are a nice increasing sequence of trees, we can easily see that $A$ is a $\kappa$-tree, but since $\kappa$ is weakly compact, we have a branch through all the smaller trees, which is a contradiction. So $S_0$ is bounded and non-stationary. And so $S_1$ is stationary. So the set of weakly compact cardinals below $\kappa$ is ineffable.
I am sorry if the proof is long. I hope someone can verify if it is correct or not. The main reason I am doubting it, is because I haven't seen it in the books I read. And it seems far more stronger than the main statement.