port to new spice api