yaml validation errors are not helpful if the file is empty
Metadata
Current evaluation
No evaluation has been recorded for this issue yet.
Issue body
### Bug Description
validation error is not helpful on an empty file.
(it was actually hard to find out that the file was empty because I thought I'd deleted it). The project already had a (valid) charmcraft.yaml next to it, and couldn't figure out why charmcraft wasn't liking it.
### To Reproduce
charmcraft pack
### Environment
charmcraft 3.2.2
### metadata.yaml
```yaml
# Copyright 2025 Canonical Ltd.
# See LICENSE file for licensing details.
```
### Relevant log output
```shell
❯ charmcraft pack
Invalid file: 'metadata.yaml'
Recommended resolution: Ensure metadata.yaml meets the juju metadata.yaml specification.
For more information, check out: https://juju.is/docs/sdk/metadata-yaml
Full execution log: '/home/pietro/.local/state/charmcraft/log/charmcraft-20250110-134846.839621.log'
```
Evaluation history
No evaluation history available.