Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
SatheeshP004 committed Jun 5, 2024
0 parents commit a072019
Show file tree
Hide file tree
Showing 1,710 changed files with 309,968 additions and 0 deletions.
57 changes: 57 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
[run]
source_pkgs = hummingbot
omit =
hummingbot/core/gateway/*
hummingbot/core/management/*
hummingbot/client/config/config_helpers.py
hummingbot/client/config/conf_migration.py
hummingbot/client/config/security.py
hummingbot/client/hummingbot_application.py
hummingbot/client/command/*
hummingbot/client/settings.py
hummingbot/client/ui/completer.py
hummingbot/client/ui/layout.py
hummingbot/client/tab/*
hummingbot/client/ui/parser.py
hummingbot/connector/derivative/position.py
hummingbot/connector/exchange/bitfinex*
hummingbot/connector/exchange/coinbase_pro*
hummingbot/connector/exchange/foxbit*
hummingbot/connector/exchange/hitbtc*
hummingbot/connector/exchange/injective_v2/account_delegation_script.py
hummingbot/connector/exchange/paper_trade*
hummingbot/connector/gateway/**
hummingbot/connector/test_support/*
hummingbot/core/utils/gateway_config_utils.py
hummingbot/core/utils/kill_switch.py
hummingbot/core/utils/wallet_setup.py
hummingbot/connector/mock*
hummingbot/strategy/*/start.py
hummingbot/strategy/dev*
hummingbot/user/user_balances.py
hummingbot/connector/exchange/cube/cube_ws_protobufs/*
hummingbot/strategy_v2/backtesting/*
dynamic_context = test_function
branch = true

[report]
fail_under = 70
precision = 2
skip_empty = true
exclude_lines =
@(abc\.)?abstractmethod
if TYPE_CHECKING:
pragma: no cover
if __name__ == .__main__.:
if 0:
raise AssertionError
raise NotImplementedError
if settings.DEBUG
except asyncio.exceptions.TimeoutError:

[html]
directory = coverage_html_report
show_contexts = true

[xml]
output = coverage.xml
13 changes: 13 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/data
/logs
/build
/dist
/.git
/.github
.DS_Store
/conf_backup
/conf/strategies/*.yml
/conf/*.yml
/conf/gateway_connections.json
/conf/.password_verification
/conf/connectors/*.yml
9 changes: 9 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[flake8]
filename = *.py, *.pyx, *.pxd
ignore = E251, E501,E702,W504,W503
per-file-ignores =
hummingbot/**/*.pyx: E225, E226, E251, E999
hummingbot/**/*.pxd: E225, E226, E251, E999
test/**/*.pyx: E225, E226, E251, E999
test/**/*.pxd: E225, E226, E251, E999
max-line-length = 120
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @hummingbot/*
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github: hummingbot
34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/bounty_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Bounty Request
description: Create a bounty for developers to work on
title: "Bounty Request "
labels: bounty
body:
- type: markdown
attributes:
value: |
## **Before Submitting:**
* Please edit the "Bounty request" to the title of the bug/issue
* Please make sure to look on our GitHub issues to avoid duplicate tickets
* You can add additional `Labels` to support this ticket (connectors, strategies, etc)
* See https://docs.hummingbot.org/governance/bounties/sponsors/ for more information on bounties
- type: textarea
id: bounty-description
attributes:
label: Description
description: "Describe what you want to do on this request"
validations:
required: true
- type: textarea
id: bounty-info
attributes:
label: Bounty
value: |
- Sponsor:
- Bounty amount:
- Developer portion:
validations:
required: true



57 changes: 57 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Bug Report
description: Create a bug report to help us improve
title: "Bug Report"
labels: bug
body:
- type: markdown
attributes:
value: |
## **Before Submitting:**
* Please edit the "Bug Report" to the title of the bug or issue
* Please make sure to look on our GitHub issues to avoid duplicate tickets
* You can add additional `Labels` to support this ticket (connectors, strategies, etc)
* If this is something to do with installation and how to's we would recommend to visit our [Discord server](https://discord.gg/hummingbot) and [Hummingbot docs](https://docs.hummingbot.org/)
- type: textarea
id: what-happened
attributes:
label: Describe the bug
description: A clear and concise description of the bug or issue. Please make sure to add screenshots and error message to help us investigate
placeholder: Tell us what happened?
validations:
required: true
- type: textarea
id: reproduce
attributes:
label: Steps to reproduce
description: A concise description of the steps to reproduce the buggy behavior
value: |
1.
2.
3.
validations:
required: true
- type: input
id: version
attributes:
label: Release version
description: Include your bot version number (Can be found at the upper left corner of your CLI)
validations:
required: true
- type: dropdown
id: build
attributes:
label: Type of installation
description: What type of installation did you use?
options:
- Source
- Docker
validations:
required: true
- type: textarea
id: attachment
attributes:
label: Attach required files
description: Please attach your config file and log file located on the "../hummingbot/logs/" folder. It would be difficult for us to help you without those!
validations:
required: false
35 changes: 35 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Feature request
description: Suggest an idea that will improve the Hummingbot codebase
title: "Feature Request"
labels: enhancement
body:
- type: markdown
attributes:
value: |
## **Before Submitting:**
* Please edit the "Feature Request" to the title of the feature
* Please make sure to look on our GitHub issues to avoid duplicate tickets
* You can add additional `Labels` to support this ticket (connectors, strategies, etc)
* If this is something to do with installation and how to's we would recommend to visit our [Discord server](https://discord.gg/hummingbot) and [Hummingbot docs](https://docs.hummingbot.org/)
- type: textarea
id: feature-suggestion
attributes:
label: Feature Suggestion
description: A clear and concise description of the feature request. If you have looked at the code and know exactly what code changes are needed then please consider submitting a pull request instead.
placeholder: How you want to achieve the desired behavior
validations:
required: true
- type: textarea
id: feature-impact
attributes:
label: Impact
description: A succinct description of why you want the desired behavior specified above.
placeholder: The desired behavior will allow me to..
validations:
required: true
- type: textarea
id: feature-additional-context
attributes:
label: Additional context
description: Add any other context or screenshots about the feature request here (optional)
44 changes: 44 additions & 0 deletions .github/actions/install_env_and_hb/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: "Install environment and Hummingbot"
description: "Installs conda environment, all libraries and compiles Hummingbot"
inputs:
program-cache-hit:
required: true
description: "Value of truth regarding the program cache being hit or not"
dependencies-cache-hit:
required: true
description: "Value of truth regarding the program cache being hit or not"
runs:
using: "composite"
steps:
# Install python/conda to check if core code has changed
- uses: actions/setup-python@v4
if: ${{inputs.program-cache-hit}} != 'true' || ${{inputs.dependencies-cache-hit}} != 'true'
with:
python-version: 3.x

# Install pre_commit if code has changed
- name: Install pre_commit
if: ${{inputs.program-cache-hit}} != 'true' || ${{inputs.dependencies-cache-hit}} != 'true'
shell: bash
run: |
conda install -c conda-forge pre_commit
# Install hummingbot env if environment.yml has changed
- name: Install Hummingbot
if: ${{inputs.dependencies-cache-hit}} != 'true'
shell: bash -l {0}
run: |
./install
# Compile and run tests if code has changed
- name: Compile Hummingbot
shell: bash
if: ${{inputs.program-cache-hit}} != 'true' || ${{inputs.dependencies-cache-hit}} != 'true'
env:
WITHOUT_CYTHON_OPTIMIZATIONS: 'true'
run: |
source $CONDA/etc/profile.d/conda.sh
conda info --envs
conda activate hummingbot
conda env export
./compile
16 changes: 16 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
**Before submitting this PR, please make sure**:

- [ ] Your code builds clean without any errors or warnings
- [ ] You are using approved title ("feat/", "fix/", "docs/", "refactor/")

**A description of the changes proposed in the pull request**:



**Tests performed by the developer**:



**Tips for QA testing**:


80 changes: 80 additions & 0 deletions .github/workflows/docker_buildx_workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
name: Client Docker Buildx Workflow

on:
pull_request:
types: [closed]
branches:
- master
- development
release:
types: [published, edited]

jobs:
build_pr:
if: github.event_name == 'pull_request' && github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/[email protected]

- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Development Image
if: github.base_ref == 'development'
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: hummingbot/hummingbot:development

- name: Build and push Latest Image
if: github.base_ref == 'master'
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: hummingbot/hummingbot:latest

build_release:
if: github.event_name == 'release'
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/[email protected]

- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Extract tag name
id: get_tag
run: echo ::set-output name=VERSION::version-${GITHUB_REF#refs/tags/v}

- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: hummingbot/hummingbot:${{ steps.get_tag.outputs.VERSION }}
Loading

0 comments on commit a072019

Please sign in to comment.