We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 345bf1c commit 0d0d06bCopy full SHA for 0d0d06b
flit_core/flit_core/config.py
@@ -603,7 +603,14 @@ def read_pep621_metadata(proj, path) -> LoadedConfig:
603
raise ConfigError(
604
"[project.license] should specify file or text, not both"
605
)
606
- lc.referenced_files.append(license_tbl['file'])
+ license_f = license_tbl['file']
607
+ if isabs_ish(license_f):
608
+ raise ConfigError(
609
+ f"License file path ({license_f}) cannot be an absolute path"
610
+ )
611
+ if not (path.parent / license_f).is_file():
612
+ raise ConfigError(f"License file {license_f} does not exist")
613
+ license_files.add(license_tbl['file'])
614
elif 'text' in license_tbl:
615
pass
616
else:
0 commit comments