Tank with gas vent and inlet or outlet