Skip to content

Commit

Permalink
Merge pull request #88 from PtPrashantTripathi/autofix/alert-156-1f98…
Browse files Browse the repository at this point in the history
…6c89d5

Fix code scanning alert no. 156: Unvalidated dynamic method call
  • Loading branch information
PtPrashantTripathi authored Oct 1, 2024
2 parents 8f5b995 + 35237d1 commit 3572fe1
Show file tree
Hide file tree
Showing 33 changed files with 3,889 additions and 3,752 deletions.
23 changes: 14 additions & 9 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,20 +21,21 @@ repos:
- id: trailing-whitespace

- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.27.4
rev: 0.29.3
hooks:
- id: check-github-workflows

- repo: https://github.com/codespell-project/codespell
rev: "v2.2.6"
rev: "v2.3.0"
hooks:
- id: codespell

- repo: https://github.com/psf/black
rev: 24.4.2
rev: 24.8.0
hooks:
- id: black
language_version: python3
- id: black-jupyter

- repo: https://github.com/pycqa/isort
rev: 5.13.2
Expand All @@ -44,10 +45,14 @@ repos:
name: isort (python)

- repo: https://github.com/nbQA-dev/nbQA
rev: 1.9.0
rev: 1.8.7
hooks:
- id: nbqa-black
- id: nbqa-pyupgrade
args: ["--py37-plus"]
- id: nbqa-isort
args: ["--order-by-type", "--length-sort", "black"]
- id: nbqa-pyupgrade
args: ["--py37-plus"]
- id: nbqa-isort
args: ["--order-by-type", "--length-sort", "black"]

- repo: https://github.com/asottile/pyupgrade
rev: v3.17.0
hooks:
- id: pyupgrade
2 changes: 1 addition & 1 deletion CONFIG/DATA_CONTRACTS/BRONZE/StockData.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"data_schema": [
{
"col_name": "date",
"data_type": "datetime64[ns, asia/kolkata]"
"data_type": "datetime64[ns, Asia/Kolkata]"
},
{
"col_name": "open",
Expand Down
12 changes: 6 additions & 6 deletions CONFIG/DATA_CONTRACTS/BRONZE/Symbol.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,27 @@
"data_schema": [
{
"col_name": "instrument_type",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "scrip_name",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "scrip_code",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "isin",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "isin_reinvestment",
"data_type": "object"
"data_type": "string"
}
]
}
10 changes: 5 additions & 5 deletions CONFIG/DATA_CONTRACTS/GOLD/CurrentHolding.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,27 @@
"data_schema": [
{
"col_name": "scrip_name",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "exchange",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "segment",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "datetime",
"data_type": "datetime64[ns]"
},
{
"col_name": "side",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "quantity",
Expand Down
4 changes: 2 additions & 2 deletions CONFIG/DATA_CONTRACTS/GOLD/Dividend.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
},
{
"col_name": "segment",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "dividend_amount",
Expand Down
8 changes: 4 additions & 4 deletions CONFIG/DATA_CONTRACTS/GOLD/Holding.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,19 @@
},
{
"col_name": "segment",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "exchange",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "scrip_name",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "holding_quantity",
Expand Down
14 changes: 7 additions & 7 deletions CONFIG/DATA_CONTRACTS/GOLD/ProfitLoss.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@
"data_schema": [
{
"col_name": "exchange",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "segment",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "scrip_name",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "position",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "quantity",
Expand All @@ -30,7 +30,7 @@
},
{
"col_name": "open_side",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "open_price",
Expand All @@ -46,7 +46,7 @@
},
{
"col_name": "close_side",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "close_price",
Expand Down
6 changes: 3 additions & 3 deletions CONFIG/DATA_CONTRACTS/SILVER/StockEvents.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
"data_schema": [
{
"col_name": "date",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "event",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "value",
Expand Down
4 changes: 2 additions & 2 deletions CONFIG/DATA_CONTRACTS/SILVER/StockPrice.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"data_schema": [
{
"col_name": "date",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "open",
Expand Down
10 changes: 5 additions & 5 deletions CONFIG/DATA_CONTRACTS/SILVER/Symbol.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@
"data_schema": [
{
"col_name": "instrument_type",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "isin",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "scrip_name",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "scrip_code",
"data_type": "object"
"data_type": "string"
}
]
}
6 changes: 3 additions & 3 deletions CONFIG/DATA_CONTRACTS/SILVER/TradeHistory.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@
},
{
"col_name": "amount",
"data_type": "Float64"
"data_type": "float64"
},
{
"col_name": "quantity",
"data_type": "Float64"
"data_type": "float64"
},
{
"col_name": "price",
"data_type": "Float64"
"data_type": "float64"
},
{
"col_name": "expiry_date",
Expand Down
8 changes: 4 additions & 4 deletions CONFIG/DATA_CONTRACTS/SOURCE/Holding.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
"data_schema": [
{
"col_name": "segment",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "exchange",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "symbol",
"data_type": "object"
"data_type": "string"
},
{
"col_name": "min_date",
Expand All @@ -22,7 +22,7 @@
},
{
"col_name": "isin",
"data_type": "object"
"data_type": "string"
}
]
}
Loading

0 comments on commit 3572fe1

Please sign in to comment.