Add a local slicing test.
Fix the slicing bug.

Prevent `local_from_global` induced negative indices in local maps.

And refactor a bit.
Remove another skiptest.
Fix the local slicing test after API change.