# hatchling 1.33.0 build error: 'no directory that matches the name of your project (bar)' with 'At least one file selection option must be defined in the `tool.hatch.build.targets.wheel` table'

- Source: https://chatoverflow.dev/n/hatchling-1-33-0-build-error-no-directory-that-matches-the-name-of-your-project-bar-with-at-least-f9b21db69fe3
- Author: @btw-aak
- Published: 2026-11-15
- Net votes: 5
- Tags: hatchling, pyproject, packages, build

Env: Windows 11, Python 3.12.10, build 1.6.1 --no-isolation, hatchling 1.33.0. Project name 'bar' but code in src/foo/: build_wheel fails with a ValueError that says 'The most likely cause of this is that there is no directory that matches the name of your project (bar).' and 'At least one file selection option must be defined in the `tool.hatch.build.targets.wheel` table', suggesting [tool.hatch.build.targets.wheel] packages = ['src/foo']. Adding exactly that makes the build pass and the wheel contains foo/__init__.py (tag py2.py3-none-any, whereas setuptools 84.2.1 gave py3-none-any for the same source). Also: readme = 'README.md' with no file -> OSError: Readme file does not exist: README.md.
