Skip to content

Conversation

@asloobq
Copy link
Contributor

@asloobq asloobq commented Jun 11, 2024

1] Moving duplicate info to official guide. uid2docs update is still WIP
2] Added package setuptools and bitarray to list of dependencies
3] Cleaned up metadata from setup.cfg file as that's the old way of package management and build was throwing warnings about them.

Build error due to missing dependency

(my_venv) ➜  uid2-client-python git:(main) ✗ pip install uid2-client
Collecting uid2-client
  Using cached uid2_client-2.4.0-py3-none-any.whl.metadata (2.0 kB)
Collecting pycryptodome (from uid2-client)
  Using cached pycryptodome-3.20.0-cp35-abi3-macosx_10_9_universal2.whl.metadata (3.4 kB)
Using cached uid2_client-2.4.0-py3-none-any.whl (35 kB)
Using cached pycryptodome-3.20.0-cp35-abi3-macosx_10_9_universal2.whl (2.4 MB)
Installing collected packages: pycryptodome, uid2-client
Successfully installed pycryptodome-3.20.0 uid2-client-2.4.0
(my_venv) ➜  uid2-client-python git:(main) ✗ python3 examples/sample_identity_map_client.py https://operator-integ.uidapi.com <API_KEY> <SECRET> asloob@example.com
Traceback (most recent call last):
  File "/Users/asloob.qureshi/work/workspace/test-python/uid2-client-python/examples/sample_identity_map_client.py", line 3, in <module>
    from uid2_client import IdentityMapClient, IdentityMapInput
  File "/Users/asloob.qureshi/work/workspace/test-python/uid2-client-python/my_venv/lib/python3.10/site-packages/uid2_client/__init__.py", line 12, in <module>
    from .client import *
  File "/Users/asloob.qureshi/work/workspace/test-python/uid2-client-python/my_venv/lib/python3.10/site-packages/uid2_client/client.py", line 10, in <module>
    from .encryption import *
  File "/Users/asloob.qureshi/work/workspace/test-python/uid2-client-python/my_venv/lib/python3.10/site-packages/uid2_client/encryption.py", line 9, in <module>
    from bitarray import bitarray
ModuleNotFoundError: No module named 'bitarray'

Build Warnings:

* Getting build dependencies for sdist...
/private/var/folders/86/w50mq9fn1wn60dhjjxkhgjnc0000gq/T/build-env-ot1kp0cy/lib/python3.10/site-packages/setuptools/config/setupcfg.py:293: _DeprecatedConfig: Deprecated config in `setup.cfg`
!!

        ********************************************************************************
        The license_file parameter is deprecated, use license_files instead.

        This deprecation is overdue, please update your project and remove deprecated
        calls to avoid build errors in the future.

        See https://setuptools.pypa.io/en/latest/userguide/declarative_config.html for details.
        ********************************************************************************

!!
  parsed = self.parsers.get(option_name, lambda x: x)(value)
/private/var/folders/86/w50mq9fn1wn60dhjjxkhgjnc0000gq/T/build-env-ot1kp0cy/lib/python3.10/site-packages/setuptools/config/_apply_pyprojecttoml.py:73: _WouldIgnoreField: `requires-python` defined outside of `pyproject.toml` would be ignored.
!!

        ********************************************************************************
        ##########################################################################
        # configuration would be ignored/result in error due to `pyproject.toml` #
        ##########################################################################

        The following seems to be defined outside of `pyproject.toml`:

        `requires-python = <SpecifierSet('>=3.6')>`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `requires-python` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/declaring-project-metadata/

        For the time being, `setuptools` will still consider the given value (as a
        **transitional** measure), but please note that future releases of setuptools will
        follow strictly the standard.

        To prevent this warning, you can list `requires-python` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.

        This deprecation is overdue, please update your project and remove deprecated
        calls to avoid build errors in the future.
        ********************************************************************************

!!
  _handle_missing_dynamic(dist, project_table)
/private/var/folders/86/w50mq9fn1wn60dhjjxkhgjnc0000gq/T/build-env-ot1kp0cy/lib/python3.10/site-packages/setuptools/config/_apply_pyprojecttoml.py:73: _WouldIgnoreField: `license` defined outside of `pyproject.toml` would be ignored.
!!

        ********************************************************************************
        ##########################################################################
        # configuration would be ignored/result in error due to `pyproject.toml` #
        ##########################################################################

        The following seems to be defined outside of `pyproject.toml`:

        `license = 'Apache 2.0'`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `license` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/declaring-project-metadata/

        For the time being, `setuptools` will still consider the given value (as a
        **transitional** measure), but please note that future releases of setuptools will
        follow strictly the standard.

        To prevent this warning, you can list `license` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.

        This deprecation is overdue, please update your project and remove deprecated
        calls to avoid build errors in the future.
        ********************************************************************************

!!
  _handle_missing_dynamic(dist, project_table)
/private/var/folders/86/w50mq9fn1wn60dhjjxkhgjnc0000gq/T/build-env-ot1kp0cy/lib/python3.10/site-packages/setuptools/config/_apply_pyprojecttoml.py:73: _WouldIgnoreField: `keywords` defined outside of `pyproject.toml` would be ignored.
!!

        ********************************************************************************
        ##########################################################################
        # configuration would be ignored/result in error due to `pyproject.toml` #
        ##########################################################################

        The following seems to be defined outside of `pyproject.toml`:

        `keywords = ['uid2']`

        According to the spec (see the link below), however, setuptools CANNOT
        consider this value unless `keywords` is listed as `dynamic`.

        https://packaging.python.org/en/latest/specifications/declaring-project-metadata/

        For the time being, `setuptools` will still consider the given value (as a
        **transitional** measure), but please note that future releases of setuptools will
        follow strictly the standard.

        To prevent this warning, you can list `keywords` under `dynamic` or alternatively
        remove the `[project]` table from your file and rely entirely on other means of
        configuration.

        This deprecation is overdue, please update your project and remove deprecated
        calls to avoid build errors in the future.
        ********************************************************************************

!!

@asloobq asloobq changed the title [UID2-3320] Remove duplicate info and point to official guide [UID2-3320] Clean up dependencies and point to official guide Jun 12, 2024
@asloobq asloobq marked this pull request as ready for review June 12, 2024 18:38

The SDK can be installed using pip.
```
pip install uid2-client
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to mention how to run the pip in the readme

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll be moving that info to the official guide

@asloobq asloobq merged commit 5ae9b09 into main Jun 14, 2024
@asloobq asloobq deleted the aaq-UID2-3320-update-readme-official-guide branch June 14, 2024 16:55
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

Successfully merging this pull request may close these issues.

4 participants