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

fancy_pypi_readme: TypeError: build_text() missing 1 required positional argument: 'version' #592

Closed
njzjz opened this issue Dec 31, 2023 · 2 comments

Comments

@njzjz
Copy link
Contributor

njzjz commented Dec 31, 2023

I got this error just now:

    Running command Preparing metadata (pyproject.toml)
    Traceback (most recent call last):
      File "/opt/python/cp311-cp311/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 351, in <module>
        main()
      File "/opt/python/cp311-cp311/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 333, in main
        json_out['return_val'] = hook(**hook_input['kwargs'])
                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/python/cp311-cp311/lib/python3.11/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
        return hook(metadata_directory, config_settings)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/tmp/pip-build-env-5hc5unxx/overlay/lib/python3.11/site-packages/scikit_build_core/build/__init__.py", line 72, in prepare_metadata_for_build_wheel
        return _build_wheel_impl(
               ^^^^^^^^^^^^^^^^^^
      File "/tmp/pip-build-env-5hc5unxx/overlay/lib/python3.11/site-packages/scikit_build_core/build/wheel.py", line 134, in _build_wheel_impl
        metadata = get_standard_metadata(pyproject, settings)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/tmp/pip-build-env-5hc5unxx/overlay/lib/python3.11/site-packages/scikit_build_core/settings/metadata.py", line 36, in get_standard_metadata
        new_pyproject_dict["project"][field] = provider.dynamic_metadata(field, config)
                                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/tmp/pip-build-env-5hc5unxx/overlay/lib/python3.11/site-packages/scikit_build_core/metadata/fancy_pypi_readme.py", line 39, in dynamic_metadata
        "text": build_text(config.fragments, config.substitutions)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    TypeError: build_text() missing 1 required positional argument: 'version'
    error: subprocess-exited-with-error
    
    × Preparing metadata (pyproject.toml) did not run successfully.
    │ exit code: 1
    ╰─> See above for output.

"text": build_text(config.fragments, config.substitutions)

It seems the upstream API was changed:

@hynek
Copy link

hynek commented Jan 1, 2024

this should be fixed by hatch-fancy-pypi-readme 24.1.0 that is now on PyPI

@njzjz
Copy link
Contributor Author

njzjz commented Jan 1, 2024

I confirm it works. Thanks!

@njzjz njzjz closed this as completed Jan 1, 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

2 participants