vortex-api 2.1.1__tar.gz → 2.1.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: vortex_api
3
- Version: 2.1.1
3
+ Version: 2.1.3
4
4
  Summary: Vortex APIs to place orders in Rupeezy application
5
5
  Author-email: "Astha Credit & Securities Pvt Ltd." <tech@rupeezy.in>
6
6
  License: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "vortex_api"
7
- version = "2.1.1"
7
+ version = "2.1.3"
8
8
  description = "Vortex APIs to place orders in Rupeezy application"
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }
@@ -0,0 +1 @@
1
+ __version__ = "2.1.3"
@@ -18,8 +18,11 @@ class Constants:
18
18
  NSE_FO = "NSE_FO"
19
19
  BSE_FO = "BSE_FO"
20
20
  NSE_EQUITY = "NSE_EQ"
21
+ NSE_EQ = "NSE_EQ"
21
22
  BSE_EQUITY = "BSE_EQ"
23
+ BSE_EQ = "NSE_EQ"
22
24
  NSE_CURRENCY = "NSE_CD"
25
+ NSE_CD = "NSE_CD"
23
26
  MCX = "MCX_FO"
24
27
 
25
28
  def __str__(self):
@@ -14,7 +14,14 @@ Usage from api.py:
14
14
 
15
15
  def _is_backtestingpy(result):
16
16
  """Check if result is a backtesting.py stats object (pd.Series with _strategy key)."""
17
- return hasattr(result, "get") and result.get("_strategy") is not None
17
+ if not hasattr(result, "get"):
18
+ return False
19
+ # Primary: backtesting.py always sets _strategy
20
+ if result.get("_strategy") is not None:
21
+ return True
22
+ # Fallback: manually constructed Series with backtesting.py-style keys
23
+ _BT_KEYS = {"Sharpe Ratio", "# Trades", "Return [%]", "Win Rate [%]"}
24
+ return hasattr(result, "index") and len(_BT_KEYS & set(result.index)) >= 3
18
25
 
19
26
 
20
27
  def _is_vectorbt(result):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: vortex_api
3
- Version: 2.1.1
3
+ Version: 2.1.3
4
4
  Summary: Vortex APIs to place orders in Rupeezy application
5
5
  Author-email: "Astha Credit & Securities Pvt Ltd." <tech@rupeezy.in>
6
6
  License: MIT
@@ -1 +0,0 @@
1
- __version__ = "2.1.1"
File without changes
File without changes
File without changes