I do not understand why g(.,v) only shows non-zero components after evaluation.
{m,n,a,b,c,r,s}::Indices(values={0,1,2,3}).
#
g_{a b}::Metric.
g^{a b}::InverseMetric.
#
g:=[g_{0 0}=-1, g_{0 1}=0, g_{0 2}=1, g_{0 3}=0, g_{1 0}=0, g_{1 1}=1, g_{1 2}=0, g_{1 3}=0, g_{2 0}=1, g_{2 1}=0, g_{2 2}=1, g_{2 3}=0, g_{3 0}=0, g_{3 1}=0, g_{3 2}=0, g_{3 3}=1].
v:=[v^{0}=1, v^{1}=1, v^{2}=1, v^{3}=1];
display(v)
ex:=g_{a b} v^{a};
evaluate(ex,join(g,v), rhsonly=True);
OUTPUT gives
□_{b}
{1} = 1
{2} = 2
{3} = 1
Setting g00=1 (tather than -1 above) gives
□_{b}
{0} = 2
{1} = 1
{2} = 2
{3} = 1