ThFeAsN$_{1-x}$O$_x$ ($0leq xleq0.6$) system with heavy electron doping has been studied by the measurements of X-ray diffraction, electrical resistivity, magnetic susceptibility and specific heat. The non-doped compound exhibits superconductivity at $T_mathrm{c}^mathrm{onset}=30$ K, which is possibly due to an internal uniaxial chemical pressure that is manifested by the extremely small value of As height with respect to the Fe plane. With the oxygen substitution, the $T_mathrm{c}$ value decreases rapidly to below 2 K for $0.1leq xleq0.2$, and surprisingly, superconductivity re-appears in the range of $0.25leq xleq0.5$ with a maximum $T_mathrm{c}^mathrm{onset}$ of 17.5 K at $x=0.3$. For the normal-state resistivity, while the samples in intermediate non-superconducting interval exhibit Fermi liquid behavior, those in other regions show a non-Fermi-liquid behavior. The specific heat jump for the superconducting sample of $x=0.4$ is $Delta C/(gamma T_mathrm{c})=0.89$, which is discussed in terms of anisotropic superconducting gap. The peculiar phase diagram in ThFeAsN$_{1-x}$O$_x$ presents additional ingredients for understanding the superconducting mechanism in iron-based superconductors.