Docker compose exec can not find running container

Expected behavior

“docker-compose exec web ” run into container

Actual behavior

“docker-compose exec web ”
The message after run the command:

No container found

Information

Run “docker ps” and copy the id or name to “docker exec”, that works.

Docker version is 1.12.0-rc3-beta18.

Thanks

your container must be up
run
docker-compose up
and then
docker-compose exec web