Refactor.
Refactoring alias generation.
Cleaning up alias map code.
Fixing one more failing test.
Merge branch 'refactor/2.3'