-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4817d44
commit de810c0
Showing
28 changed files
with
4,317 additions
and
4,245 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
.github | ||
tests | ||
data | ||
.env.sample | ||
.gitignore | ||
.pylintrc | ||
Dockerfile | ||
LICENSE | ||
mypy.ini | ||
README.md | ||
.github | ||
tests | ||
data | ||
.env.sample | ||
.gitignore | ||
.pylintrc | ||
Dockerfile | ||
LICENSE | ||
mypy.ini | ||
README.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
COW_DEX_AG_SOLVER_URL=http://host.docker.internal:8000 | ||
ORDERBOOK_URL=https://barn.api.cow.fi/xdai | ||
BASE_TOKENS=0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83 | ||
NODE_URL=https://rpc.gnosis.gateway.fm | ||
SOLVER_ACCOUNT=0x7942a2b3540d1ec40b2740896f87aecb2a588731 | ||
SOLVERS=CowDexAg | ||
TRANSACTION_STRATEGY=DryRun | ||
LOG_FILTER=info | ||
COW_DEX_AG_SOLVER_URL=http://host.docker.internal:8000 | ||
ORDERBOOK_URL=https://barn.api.cow.fi/xdai | ||
BASE_TOKENS=0xDDAfbb505ad214D7b80b1f830fcCc89B60fb7A83 | ||
NODE_URL=https://rpc.gnosis.gateway.fm | ||
SOLVER_ACCOUNT=0x7942a2b3540d1ec40b2740896f87aecb2a588731 | ||
SOLVERS=CowDexAg | ||
TRANSACTION_STRATEGY=DryRun | ||
LOG_FILTER=info |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
name: "cla" | ||
|
||
on: | ||
issue_comment: | ||
types: [created] | ||
pull_request_target: | ||
types: [opened, closed, synchronize] | ||
|
||
jobs: | ||
cla: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "CLA Assistant" | ||
if: (github.event.comment.body == 'recheck' || github.event.comment.body == 'I have read the CLA Document and I hereby sign the CLA') || github.event_name == 'pull_request_target' | ||
uses: contributor-assistant/github-action@v2.2.1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
PERSONAL_ACCESS_TOKEN : ${{ secrets.ORG_TOKEN }} | ||
with: | ||
branch: 'cla-signatures' | ||
path-to-signatures: 'signatures/version1/cla.json' | ||
path-to-document: 'https://github.com/cowprotocol/cla/blob/main/CLA.md' | ||
allowlist: '*[bot]' | ||
name: "cla" | ||
|
||
on: | ||
issue_comment: | ||
types: [created] | ||
pull_request_target: | ||
types: [opened, closed, synchronize] | ||
|
||
jobs: | ||
cla: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "CLA Assistant" | ||
if: (github.event.comment.body == 'recheck' || github.event.comment.body == 'I have read the CLA Document and I hereby sign the CLA') || github.event_name == 'pull_request_target' | ||
uses: contributor-assistant/github-action@v2.2.1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
PERSONAL_ACCESS_TOKEN : ${{ secrets.ORG_TOKEN }} | ||
with: | ||
branch: 'cla-signatures' | ||
path-to-signatures: 'signatures/version1/cla.json' | ||
path-to-document: 'https://github.com/cowprotocol/cla/blob/main/CLA.md' | ||
allowlist: '*[bot]' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,36 @@ | ||
name: deploy | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
tags: [v*] | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
packages: write | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- id: meta | ||
uses: docker/metadata-action@v3 | ||
with: | ||
images: ghcr.io/${{ github.repository }} | ||
labels: | | ||
org.opencontainers.image.licenses=MIT OR Apache-2.0 | ||
- uses: docker/build-push-action@v2 | ||
with: | ||
context: . | ||
file: Dockerfile | ||
push: true | ||
tags: ${{ steps.meta.outputs.tags }} | ||
labels: ${{ steps.meta.outputs.labels }} | ||
name: deploy | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
tags: [v*] | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
packages: write | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- id: meta | ||
uses: docker/metadata-action@v3 | ||
with: | ||
images: ghcr.io/${{ github.repository }} | ||
labels: | | ||
org.opencontainers.image.licenses=MIT OR Apache-2.0 | ||
- uses: docker/build-push-action@v2 | ||
with: | ||
context: . | ||
file: Dockerfile | ||
push: true | ||
tags: ${{ steps.meta.outputs.tags }} | ||
labels: ${{ steps.meta.outputs.labels }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,29 @@ | ||
name: pull request | ||
on: | ||
pull_request: | ||
push: | ||
branches: [ main ] | ||
jobs: | ||
python: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup Python 3.10 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.10' | ||
- name: Install Requirements | ||
run: | ||
pip install -r requirements.txt | ||
- name: Lint | ||
run: | ||
pylint src/ | ||
- name: Format | ||
run: | ||
black --check ./ | ||
- name: Type Check | ||
run: | ||
mypy src --strict | ||
- name: Unit Tests | ||
run: | ||
name: pull request | ||
on: | ||
pull_request: | ||
push: | ||
branches: [ main ] | ||
jobs: | ||
python: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup Python 3.10 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.10' | ||
- name: Install Requirements | ||
run: | ||
pip install -r requirements.txt | ||
- name: Lint | ||
run: | ||
pylint src/ | ||
- name: Format | ||
run: | ||
black --check ./ | ||
- name: Type Check | ||
run: | ||
mypy src --strict | ||
- name: Unit Tests | ||
run: | ||
python -m pytest tests/unit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
*.pyc | ||
*/__pycache__ | ||
venv/ | ||
.env | ||
|
||
.idea/ | ||
.vscode/ | ||
.DS_Store | ||
*.pyc | ||
*/__pycache__ | ||
venv/ | ||
.env | ||
|
||
.idea/ | ||
.vscode/ | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
[MASTER] | ||
disable=fixme,too-few-public-methods,too-many-instance-attributes,too-many-arguments,logging-fstring-interpolation,too-many-locals,duplicate-code, def buy_amount(self) -> Decimal: | ||
|
||
extension-pkg-allow-list=pydantic | ||
[MASTER] | ||
disable=fixme,too-few-public-methods,too-many-instance-attributes,too-many-arguments,logging-fstring-interpolation,too-many-locals,duplicate-code, def buy_amount(self) -> Decimal: | ||
|
||
extension-pkg-allow-list=pydantic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
FROM python:3.10-alpine | ||
|
||
RUN apk add --update gcc libc-dev linux-headers | ||
|
||
WORKDIR /app | ||
|
||
# First copy over the requirements.txt and install dependencies, this makes | ||
# building subsequent images easier. | ||
COPY requirements.txt . | ||
RUN pip install -r requirements.txt | ||
|
||
# Copy full source (see .dockerignore) | ||
COPY . . | ||
|
||
CMD [ "python3", "-m" , "src._server"] | ||
FROM python:3.10-alpine | ||
|
||
RUN apk add --update gcc libc-dev linux-headers | ||
|
||
WORKDIR /app | ||
|
||
# First copy over the requirements.txt and install dependencies, this makes | ||
# building subsequent images easier. | ||
COPY requirements.txt . | ||
RUN pip install -r requirements.txt | ||
|
||
# Copy full source (see .dockerignore) | ||
COPY . . | ||
|
||
CMD [ "python3", "-m" , "src._server"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2022 CoW Protocol | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
MIT License | ||
Copyright (c) 2022 CoW Protocol | ||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
Oops, something went wrong.