The use of long γ-ray burst as star formation tracers is suspected to be affected by a possible dependence of the production or luminosity of these sources on the metallicity of their stellar progenitors. Selection effects are an alternative explanation. Our aim is to explore the nature of metallicity effects in long γ-ray burst populations using hydrodynamical cosmological simulations that include chemical evolution. We construct long γ-ray burst and host galaxy model populations using galaxy catalogues built from cosmological hydrodynamical simulations, making different assumptions on the nature of metallicity effects. We explore the ability of these models to reproduce an observational dataset that combines redshifts, prompt γ-ray emission observables from Swift and Fermi satellites, and HG properties from the largely unbiased BAT6 sample. Our results suggest that metallicity effects are more prompted to enhance the production rate of these sources at low metallicities, than to increase the burst luminosities. This is a statistically robust result based on the deviance information criterion. The metallicity threshold of these effects lies in the range [0.3 − 0.6]Z , but can not be constrained more precisely with present data and models. In the self-consistent star formation and metal enrichment scenario presented by our simulation, only models with a metallicity-dependent long γ-ray bust rate are successful at reproducing the γ-ray properties of these sources, their redshift distribution, and the masses and metallicities of their host galaxies, simultaneously. Models with a metallicity-dependent luminosity can reproduce observations, but are not statistically favoured in comparison to a metallicity-dependent production rate. Our simulations also predict that high metallicity hosts are possible even in the presence of a metallicity threshold for long γ-ray burst production. Our results support the view of long γ-ray bursts being produced by the collapse of low-metallicity, massive stars. This strongly suggests that they are biased tracers of the cosmic star formation at lower redshifts.