telescope-sdk


Nametelescope-sdk JSON
Version 0.1.66 PyPI version JSON
download
home_pagehttps://github.com/telescope-eng/telescope-python-sdk
SummaryTelescope Python SDK
upload_time2024-04-14 23:10:51
maintainerNone
docs_urlNone
authorOlivier Ramier
requires_python<4.0,>=3.7
licenseProprietary
keywords telescope sdk
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Telescope Python SDK

Package containing Pydantic models representing the entities used in Telescope backend systems. The source of truth
for these types lives [here](https://gotelescope.atlassian.net/wiki/spaces/~62cc5da0bb346bdf82fa14f7/pages/32899073/Data+model+changes+move+to+Person).

See [Deployment](#deployment) for instructions on how to publish a new version of this package.

## Usage

```bash
$ pip install telescope-sdk
```

To construct an entity (e.g. Person) you can use the constructor 
(please note Pydantic only accepts keyword arguments):

```python
from telescope_sdk import Person
person = Person(
    id="123",
    first_name="John Doe",
    ...
    )
```

Or, to construct from a Python dictionary object:

```python
person = Person.parse_obj({
    "id": "123",
    "first_name": "John Doe",
    ...
    })
```

If you are mapping from [PDL](https://docs.peopledatalabs.com/docs/fields) types, use the `from_pdl` method:

```python
person = Person.from_pdl({
    "id": "123",
    "firstName": "John Doe",
    ...
    })
```

* Please note that unless a field is set as "Strict", it will automatically attempt to cast any input, 
  and only throw an error if casting fails 

## Development

To make changes to this package clone the repo and follow the steps below. Please ensure that any changes to the code
base are synced with the documentation linked above.

### Installation

First set up a virtual environment to isolate dependencies. You can do this in many ways but as an example:

```bash
$ pyenv virtualenv 3.10.0 <chosen-virtualenv-name>
$ pyenv activate <chosen-virtualenv-name>
```

Note this codebase takes advantage of features from Python 3.10+ therefore you may run into errors if you attempt to use
an earlier Python version.

This project relies on Poetry for dependency management. To install Poetry follow the instructions
[here](https://python-poetry.org/docs/#installing-with-pipx) (recommend using [pipx](https://pypa.github.io/pipx/) to
install Poetry globally but manage in virtualenv).

Now ensure you have Make on your machine then run

```bash
$ make install
```

This will install the package and its dependencies in [editable mode](https://setuptools.pypa.io/en/latest/userguide/development_mode.html).

### Testing

To run tests locally, run the following command:

```bash
$ make test
```

### Linting

To run linting locally, run the following command:

```bash
$ make lint
```

## Deployment

A new package version is published to PyPI whenever a new release is created on GitHub. To create a new release follow
the following steps, from the `master` branch:

1. Update the version number in `pyproject.toml` to the new version number (use semantic versioning).
2. Create a new release on GitHub with the same version number as the one in `pyproject.toml`.
3. Draft release notes for the new version. These will be used as the package description on PyPI.
4. The new version will be published to [PyPI](https://pypi.org/) automatically.

On pushes to the `master` branch, the `sandbox-deploy` job will run and publish a new version of the package to
[TestPyPI](https://test.pypi.org/). This is useful for testing changes to the package before publishing to PyPI.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/telescope-eng/telescope-python-sdk",
    "name": "telescope-sdk",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.7",
    "maintainer_email": null,
    "keywords": "telescope, sdk",
    "author": "Olivier Ramier",
    "author_email": "olivier@gotelescope.ai",
    "download_url": "https://files.pythonhosted.org/packages/1f/f2/05f5b6bbc5b105a8a7c721872d58a5e225912e44bf5bfd485fc01bc34759/telescope_sdk-0.1.66.tar.gz",
    "platform": null,
    "description": "# Telescope Python SDK\n\nPackage containing Pydantic models representing the entities used in Telescope backend systems. The source of truth\nfor these types lives [here](https://gotelescope.atlassian.net/wiki/spaces/~62cc5da0bb346bdf82fa14f7/pages/32899073/Data+model+changes+move+to+Person).\n\nSee [Deployment](#deployment) for instructions on how to publish a new version of this package.\n\n## Usage\n\n```bash\n$ pip install telescope-sdk\n```\n\nTo construct an entity (e.g. Person) you can use the constructor \n(please note Pydantic only accepts keyword arguments):\n\n```python\nfrom telescope_sdk import Person\nperson = Person(\n    id=\"123\",\n    first_name=\"John Doe\",\n    ...\n    )\n```\n\nOr, to construct from a Python dictionary object:\n\n```python\nperson = Person.parse_obj({\n    \"id\": \"123\",\n    \"first_name\": \"John Doe\",\n    ...\n    })\n```\n\nIf you are mapping from [PDL](https://docs.peopledatalabs.com/docs/fields) types, use the `from_pdl` method:\n\n```python\nperson = Person.from_pdl({\n    \"id\": \"123\",\n    \"firstName\": \"John Doe\",\n    ...\n    })\n```\n\n* Please note that unless a field is set as \"Strict\", it will automatically attempt to cast any input, \n  and only throw an error if casting fails \n\n## Development\n\nTo make changes to this package clone the repo and follow the steps below. Please ensure that any changes to the code\nbase are synced with the documentation linked above.\n\n### Installation\n\nFirst set up a virtual environment to isolate dependencies. You can do this in many ways but as an example:\n\n```bash\n$ pyenv virtualenv 3.10.0 <chosen-virtualenv-name>\n$ pyenv activate <chosen-virtualenv-name>\n```\n\nNote this codebase takes advantage of features from Python 3.10+ therefore you may run into errors if you attempt to use\nan earlier Python version.\n\nThis project relies on Poetry for dependency management. To install Poetry follow the instructions\n[here](https://python-poetry.org/docs/#installing-with-pipx) (recommend using [pipx](https://pypa.github.io/pipx/) to\ninstall Poetry globally but manage in virtualenv).\n\nNow ensure you have Make on your machine then run\n\n```bash\n$ make install\n```\n\nThis will install the package and its dependencies in [editable mode](https://setuptools.pypa.io/en/latest/userguide/development_mode.html).\n\n### Testing\n\nTo run tests locally, run the following command:\n\n```bash\n$ make test\n```\n\n### Linting\n\nTo run linting locally, run the following command:\n\n```bash\n$ make lint\n```\n\n## Deployment\n\nA new package version is published to PyPI whenever a new release is created on GitHub. To create a new release follow\nthe following steps, from the `master` branch:\n\n1. Update the version number in `pyproject.toml` to the new version number (use semantic versioning).\n2. Create a new release on GitHub with the same version number as the one in `pyproject.toml`.\n3. Draft release notes for the new version. These will be used as the package description on PyPI.\n4. The new version will be published to [PyPI](https://pypi.org/) automatically.\n\nOn pushes to the `master` branch, the `sandbox-deploy` job will run and publish a new version of the package to\n[TestPyPI](https://test.pypi.org/). This is useful for testing changes to the package before publishing to PyPI.\n",
    "bugtrack_url": null,
    "license": "Proprietary",
    "summary": "Telescope Python SDK",
    "version": "0.1.66",
    "project_urls": {
        "Bug Tracker": "https://github.com/telescope-eng/telescope-python-sdk/issues",
        "Homepage": "https://github.com/telescope-eng/telescope-python-sdk",
        "Repository": "https://github.com/telescope-eng/telescope-python-sdk"
    },
    "split_keywords": [
        "telescope",
        " sdk"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4fd9f608b69803144d75b758f29bf39dc681e075bad7d13a5d8e6bd7e7f01aa3",
                "md5": "f764daa813fcdc1d6be62face203da6d",
                "sha256": "312d9ff39484c37b3701dd59570327af65b3feac849c4a6b06e0dacb2348465b"
            },
            "downloads": -1,
            "filename": "telescope_sdk-0.1.66-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "f764daa813fcdc1d6be62face203da6d",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.7",
            "size": 14347,
            "upload_time": "2024-04-14T23:10:49",
            "upload_time_iso_8601": "2024-04-14T23:10:49.323204Z",
            "url": "https://files.pythonhosted.org/packages/4f/d9/f608b69803144d75b758f29bf39dc681e075bad7d13a5d8e6bd7e7f01aa3/telescope_sdk-0.1.66-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1ff205f5b6bbc5b105a8a7c721872d58a5e225912e44bf5bfd485fc01bc34759",
                "md5": "0023d45f9e3b3c8a5e6a46bd0e098377",
                "sha256": "c992099b10e73a43d91b4312e6d620916437cbc9892af3f575f3762809a2c0e3"
            },
            "downloads": -1,
            "filename": "telescope_sdk-0.1.66.tar.gz",
            "has_sig": false,
            "md5_digest": "0023d45f9e3b3c8a5e6a46bd0e098377",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.7",
            "size": 12038,
            "upload_time": "2024-04-14T23:10:51",
            "upload_time_iso_8601": "2024-04-14T23:10:51.307072Z",
            "url": "https://files.pythonhosted.org/packages/1f/f2/05f5b6bbc5b105a8a7c721872d58a5e225912e44bf5bfd485fc01bc34759/telescope_sdk-0.1.66.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-14 23:10:51",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "telescope-eng",
    "github_project": "telescope-python-sdk",
    "github_not_found": true,
    "lcname": "telescope-sdk"
}
        
Elapsed time: 0.23638s