mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-10-28 13:01:38 +00:00
* This change creates a PR * start moving stuff around * data_models/_category_.json * reference/_category_.json * moving some stuff around * Introduction * Documentation updates * few broken links, clean up sidebar titles for how-to * codespell * quickstart - new provider extension * add a comment * map provider interface * quickstart for new router extension * [Docs] diataxis refactor refactor (#6425) * Start refactor * Edits * [DOCS] Reorganize and edit. Fix sidebar navigation (#6445) * Reorganize and edit. Fix sidebar navigation * Fix broken linkages * Edit --------- Co-authored-by: Igor Radovanovic <74266147+IgorWounds@users.noreply.github.com> * Fix links --------- Co-authored-by: Theodore Aptekarev <aptekarev@gmail.com> * Fix broken links * Reword CLA part in the Licensing FAQ * change titles and order suggestion - cc @IgorWounds @piiq --------- Co-authored-by: Igor Radovanovic <74266147+IgorWounds@users.noreply.github.com> Co-authored-by: James Maslek <jmaslek11@gmail.com> Co-authored-by: Theodore Aptekarev <aptekarev@gmail.com> Co-authored-by: hjoaquim <henriquecjoaquim@gmail.com>
65 lines
2.2 KiB
Plaintext
Vendored
65 lines
2.2 KiB
Plaintext
Vendored
---
|
|
title: Dependency Management
|
|
sidebar_position: 5
|
|
description: Dealing with dependencies when developing with the OpenBB Platform. Learn how to add new dependencies to the OpenBB Platform and how to add new dependencies to your custom extension.
|
|
keywords:
|
|
- OpenBB Platform
|
|
- Open source
|
|
- Python interface
|
|
- Dependency Management
|
|
---
|
|
|
|
import HeadTitle from '@site/src/components/General/HeadTitle.tsx';
|
|
|
|
<HeadTitle title="Dependency Management - Development | OpenBB Platform Docs" />
|
|
|
|
## High-Level Overview
|
|
|
|
- **Core**: Serves as the main infrastructure. All extensions and providers have `openbb-core` as a dependency.
|
|
- **Extensions**: Utility packages that leverage Core's infrastructure. Each extension is its own package.
|
|
- **Providers**: Utility packages extending functionality to different providers, where each provider is its own package.
|
|
|
|
> This page assumes that the OpenBB GitHub repo has been cloned.
|
|
|
|
## Core Dependency Management
|
|
|
|
### Installation
|
|
|
|
:::warning
|
|
Do not run these commands in an already-installed OpenBB Platform environment. Do not run both `pip` and `poetry`.
|
|
:::
|
|
|
|
- **pip**: `pip install -e OpenBBTerminal/openbb_platform/platform/core`
|
|
|
|
or
|
|
|
|
- **poetry**: `poetry install OpenBBTerminal/openbb_platform/platform/core`
|
|
|
|
### Using Poetry
|
|
|
|
Ensure you're in a fresh conda environment before adjusting dependencies.
|
|
|
|
- **Add a Dependency**: `poetry add <my-dependency>`
|
|
- **Update Dependencies**:
|
|
- All: `poetry update`
|
|
- Specific: `poetry update <my-dependency>`
|
|
- **Remove a Dependency**: `poetry remove <my-dependency>`
|
|
|
|
## Core and Extensions
|
|
|
|
### Dev Installation
|
|
|
|
For development setup, use the provided script to install all extensions and their dependencies:
|
|
|
|
- `python dev_install.py [-e|--extras]`
|
|
|
|
> **Note**: If developing an extension, avoid installing all extensions to prevent unnecessary overhead.
|
|
|
|
### Dependency Management with Poetry
|
|
|
|
- **Add Platform Extension**: `poetry add openbb-extension-name [--dev]`
|
|
- **Resolve Conflicts**: Adjust versions in `pyproject.toml` if notified by Poetry.
|
|
- **Lock Dependencies**: `poetry lock`
|
|
- **Update Platform**: `poetry update openbb-platform`
|
|
- **Documentation**: Maintain `pyproject.toml` and `poetry.lock` for a clear record of dependencies.
|