Open artifacts.gsav in truncate mode to prevent it doubling in size each time we save.
Changed to std::ofstream::trunct instead.
Clear current itypes before loading new artifacts.
Delete current artifact ids before loading new ones.
Merge branch 'pr/4281'