Skip to content

Can't install with Poetry #707

@scottix

Description

@scottix

Observed behavior

Getting an error trying to install nats-py with poetry
poetry add nats-py

Using version ^2.10.0 for nats-py

Updating dependencies
Resolving dependencies... (0.2s)

Package operations: 1 install, 0 updates, 0 removals

  - Installing nats-py (2.10.0): Failed

  AttributeError

  module 'posixpath' has no attribute 'ALLOW_MISSING'

  at /usr/lib/python3.12/tarfile.py:770 in _get_filtered_attrs
       766│ 
       767│ def _get_filtered_attrs(member, dest_path, for_data=True):
       768│     new_attrs = {}
       769│     name = member.name
    →  770│     dest_path = os.path.realpath(dest_path, strict=os.path.ALLOW_MISSING)
       771│     # Strip leading / (tar's directory separator) from filenames.
       772│     # Include os.sep (target OS directory separator) as well.
       773│     if name.startswith(('/', os.sep)):
       774│         name = new_attrs['name'] = member.path.lstrip('/' + os.sep)

Cannot install nats-py.

running in venv
pip install nats-py works

Expected behavior

Should be able to install.

Server and client version

Nats-py 2.10.0

Host environment

Ubuntu 24.04.2 LTS

Poetry
Version: 2.1.3
Python:  3.12.3

Virtualenv
Python:         3.12.3
Implementation: CPython
Path:           <path>/.venv
Executable:    <path>/.venv/bin/python
Valid:          True

Base
Platform:   linux
OS:         posix
Python:     3.12.3
Path:       /usr
Executable: /usr/bin/python3.12

Steps to reproduce

  1. create new project with poetry poetry init
  2. add nats-py poetry add nats-py

Metadata

Metadata

Assignees

No one assigned

    Labels

    defectSuspected defect such as a bug or regression

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions