θ[q_Real, K_Integer] := 
      2 (q^(1/4)) (∑_(k = 0)^K)(((((-1))^k) (q^(k (k + 1))))/(2 k + 1))
sol7[prec_, K_] := 
      Block[{$MinPrecision = prec}, 
        N[FindRoot[θ[(E^(-(π^2) t)), 
                K] == (π/(2 (Sqrt[5]))), {t, 0.4, 0.5}, 
            WorkingPrecision -> 2 prec, PrecisionGoal -> prec, 
            MaxIterations -> 1000], prec]]
kMax1[
          digits_] := ⌈((Sqrt[digits * Log[10]])/(π (Sqrt[0.424]))) - (3/2)⌉;
kMax2[digits_] := (s = sol7[digits, K = kMax1[digits]]; 
          While[s ≠ (s = sol7[digits, --K])]; 
          K + 1);

{#, First[Evaluate[Timing[sol7[#, kMax1[#]]]]], kMax2[#], 
            kMax2[#]} & /@ {10, 100, 1000, 10000} // TableForm