If you want to avoid a route matching a static file that exists physically, simply put the static middleware before the call to the app.router.
Then the static file (such as robots.txt) will be delivered and these calls will not get through to your routing.
Problem solved ;-).