fiberwise-quasi-compact implies quasi-compact?

Here is a counterexample:

Example. We will define $X$ as a union of affine varieties $$U_0 \subseteq U_1 \subseteq \ldots$$ as follows: start with $U_0 = \mathbf A^1 \times (\mathbf A^1 \setminus 0) \subseteq \mathbf A^2 = V_0$ with its natural projection to $\mathbf A^1$, and let $Z_0 = \mathbf A^1 \times 0$ be the complement of $U_0$ in $V_0$.

Choose a sequence of points $x_1,x_2,\ldots$ on $\mathbf A^1$. Define $V_i$ as the blowup of $V_0$ in the points $(x_1,0), \ldots, (x_i,0)$, so we have maps $$\ldots \to V_i \to V_{i-1} \to \ldots \to V_0.$$ Let $E_i$ be the exceptional divisor for $V_i \to V_{i-1}$, let $Z_i$ be the strict transform of $Z_0$ in $V_i$, and let $U_i$ be its complement in $V_i$. For each $i$, the centre of the blowup $V_i \to V_{i-1}$ is contained in $Z_{i-1}$, giving an isomorphism $$V_i\setminus(E_i \cup Z_i) \stackrel\sim\longrightarrow V_{i-1}\setminus Z_{i-1},$$ hence an open immersion $$U_{i-1} = V_{i-1}\setminus Z_{i-1} \cong V_i\setminus (E_i \cup Z_i) \hookrightarrow V_i \setminus Z_i = U_i.$$ Define $X$ as the union. The maps $U_i \to \mathbf A^1$ are compatible, so they give a map $X \to \mathbf A^1$. It is flat since $X$ is integral and dominant over the Dedekind scheme $\mathbf A^1$. It is separated and locally of finite type since $X \to \operatorname{Spec} k$ is. Finally, the fibres are quasi-compact: each step $U_{i-1} \hookrightarrow U_i$ only modifies the fibre over $x_i$. But $X$ itself is not quasi-compact. $\square$


Let $X$ be the scheme obtained by gluing the generic points of all $\operatorname{Spec}\mathcal{O}_p$ for all closed points $p$ of $\mathbb{A}^1_{\mathbb C}$. The obvious morphism $X \to \mathbb{A}^1_{\mathbb C}$ is a bijection, but $X$ is not quasi-compact.