Fix to reset the generated namespace number

Test has been included. Thanks!