The new include: functionality does not actually use the env-files.
As far as I can tell, the code does read them, but they do not appear to be actually added to the interpolation environment of the compose file they belong to. As such, variables set in the env files are not applied to the included project.
Variables set in the env file of the main project are correctly applied to the included project though.
With the following set of files, the ${SUB_VAR} variable doesn't get set:
# compose.yaml
include:
- path: subcompose.yaml
env_file: sub.env
# subcompose.yaml
services:
anyservice:
image: ${SUB_VAR}
# sub.env
SUB_VAR=some_value