Escape Button doesnt work since Update to Sierra
In keyboard preferences, enable the "Show input in menu bar" option under the Input Sources tab.

Then in the menu bar Show the Keyboard Viewer.

You can press the escape key with the mouse and then connect an external keyboard and see when the key is being pressed.

If the external works and the internal fails - you need hardware repair. If neither escape physical key presses - then your software or keyboard mapping are messed up.

You could either figure out why or make a backup and erase install. Hard to guess which of those would take you less time, but those are the quick options for you if it's software and not hardware.