Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

there is no directory that matches the name of your project (kaggle) #611

Closed
astariul opened this issue Jul 24, 2024 · 10 comments
Closed

there is no directory that matches the name of your project (kaggle) #611

astariul opened this issue Jul 24, 2024 · 10 comments

Comments

@astariul
Copy link

astariul commented Jul 24, 2024

I tried installing the newest kaggle version (1.6.15) with :

pip install -U kaggle

and it fails with :

ValueError: Unable to determine which files to ship inside the wheel using the following heuristics: https://hatch.pypa.io/latest/plugins/builder/wheel/#default-file-selection

The most likely cause of this is that there is no directory that matches the name of your project (kaggle).

Full stacktrace
Collecting kaggle
  Downloading kaggle-1.6.15.tar.gz (9.1 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [35 lines of output]
      Traceback (most recent call last):
        File "/Users/remondn/miniconda3/envs/arc/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/Users/remondn/miniconda3/envs/arc/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
        File "/Users/remondn/miniconda3/envs/arc/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
          whl_basename = backend.build_wheel(metadata_directory, config_settings)
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/build.py", line 58, in build_wheel
          return os.path.basename(next(builder.build(directory=wheel_directory, versions=['standard'])))
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/plugin/interface.py", line 155, in build
          artifact = version_api[version](directory, **build_data)
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/wheel.py", line 475, in build_standard
          for included_file in self.recurse_included_files():
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/plugin/interface.py", line 176, in recurse_included_files
          yield from self.recurse_selected_project_files()
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/plugin/interface.py", line 180, in recurse_selected_project_files
          if self.config.only_include:
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/config.py", line 806, in only_include
          only_include = only_include_config.get('only-include', self.default_only_include()) or self.packages
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/wheel.py", line 260, in default_only_include
          return self.default_file_selection_options.only_include
        File "/Users/remondn/miniconda3/envs/arc/lib/python3.9/functools.py", line 993, in __get__
          val = self.func(instance)
        File "/private/var/folders/ym/2ck43xl55bl72zzn078bb7s40000gn/T/pip-build-env-59i7mpja/overlay/lib/python3.9/site-packages/hatchling/builders/wheel.py", line 248, in default_file_selection_options
          raise ValueError(message)
      ValueError: Unable to determine which files to ship inside the wheel using the following heuristics: https://hatch.pypa.io/latest/plugins/builder/wheel/#default-file-selection
      
      The most likely cause of this is that there is no directory that matches the name of your project (kaggle).
      
      At least one file selection option must be defined in the `tool.hatch.build.targets.wheel` table, see: https://hatch.pypa.io/latest/config/build/
      
      As an example, if you intend to ship a directory named `foo` that resides within a `src` directory located at the root of your project, you can define the following:
      
      [tool.hatch.build.targets.wheel]
      packages = ["src/foo"]
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

pip install kaggle==1.6.14 works fine.

Am I doing something wrong or the latest version is messed up ?

@stevemessick @jplotts

@inkyusa
Copy link

inkyusa commented Jul 24, 2024

I also encountered this error.

@daviddavo
Copy link

daviddavo added a commit to Grasia/dao-scripts that referenced this issue Jul 24, 2024
@hzgnpu
Copy link

hzgnpu commented Jul 24, 2024

Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [43 lines of output]
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()
File "/usr/local/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
whl_basename = backend.build_wheel(metadata_directory, config_settings)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/build.py", line 58, in build_wheel
return os.path.basename(next(builder.build(directory=wheel_directory, versions=['standard'])))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/plugin/interface.py", line 155, in build
artifact = version_api[version](directory, **build_data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/wheel.py", line 475, in build_standard
for included_file in self.recurse_included_files():
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/plugin/interface.py", line 176, in recurse_included_files
yield from self.recurse_selected_project_files()
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/plugin/interface.py", line 180, in recurse_selected_project_files
if self.config.only_include:
^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/config.py", line 806, in only_include
only_include = only_include_config.get('only-include', self.default_only_include()) or self.packages
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/wheel.py", line 260, in default_only_include
return self.default_file_selection_options.only_include
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/Cellar/[email protected]/3.11.7_1/Frameworks/Python.framework/Versions/3.11/lib/python3.11/functools.py", line 1001, in get
val = self.func(instance)
^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/hs/g4fh0zwn58z_tvc4t4fg2mqw0000gn/T/pip-build-env-wtjjnpmv/overlay/lib/python3.11/site-packages/hatchling/builders/wheel.py", line 248, in default_file_selection_options
raise ValueError(message)
ValueError: Unable to determine which files to ship inside the wheel using the following heuristics: https://hatch.pypa.io/latest/plugins/builder/wheel/#default-file-selection

  The most likely cause of this is that there is no directory that matches the name of your project (kaggle).
  
  At least one file selection option must be defined in the `tool.hatch.build.targets.wheel` table, see: https://hatch.pypa.io/latest/config/build/
  
  As an example, if you intend to ship a directory named `foo` that resides within a `src` directory located at the root of your project, you can define the following:
  
  [tool.hatch.build.targets.wheel]
  packages = ["src/foo"]

@satishjasthi
Copy link

I tried installing the newest kaggle version (1.6.15) with :

pip install -U kaggle

and it fails with :

ValueError: Unable to determine which files to ship inside the wheel using the following heuristics: https://hatch.pypa.io/latest/plugins/builder/wheel/#default-file-selection
The most likely cause of this is that there is no directory that matches the name of your project (kaggle).

Full stacktrace
pip install kaggle==1.6.14 works fine.

Am I doing something wrong or the latest version is messed up ?

@stevemessick @jplotts

Im also facing same issue

@psinger
Copy link

psinger commented Jul 24, 2024

yes, this new version is broken

@RubTalha
Copy link

Yup same here: https://stackoverflow.com/questions/78787980/valueerror-unable-to-determine-which-files-to-ship-inside-the-wheel-using-the-f/78788009#78788009

@amotl
Copy link

amotl commented Jul 24, 2024

Hi there,

we also tripped into this issue on our CI systems today 1. We fixed it by downgrading.

With kind regards,
Andreas.

Footnotes

  1. https://github.com/crate/cratedb-toolkit/actions/runs/10075981373/job/27855377353?pr=205#step:5:233

@stevemessick
Copy link
Contributor

I apologize for the problem. Apparently I created a bad installation. I've been trying to solve the problem and have made some progress. I will have to create a new release to permanently fix it, but there is a work-around if anyone wants to use 1.6.15 now. This worked for me:

mkdir kaggle
pip install kaggle

Obviously, I didn't have any trouble installing it when I tested it. But, I had a kaggle directory in my pwd, and when I tried installing it elsewhere I encountered the same problem you all are seeing.

I'm starting a 1.6.16 release now.

@oxmwh
Copy link

oxmwh commented Jul 24, 2024

1.6.16 works now, thank you for your service dear @stevemessick

@stevemessick
Copy link
Contributor

Fixed in 1.6.17.

daviddavo added a commit to Grasia/dao-scripts that referenced this issue Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants