From 720bbcf0196d363d621beeced8fba711990d075d Mon Sep 17 00:00:00 2001 From: Kevin Johnson Date: Mon, 31 Jan 2022 08:47:12 -0800 Subject: [PATCH 1/2] Update Bug Report --- .github/ISSUE_TEMPLATE/bug_report.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 033731b..34d74a6 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -18,7 +18,7 @@ print(ta.version) $ pip list ``` -**Upgrade.** +**Did you upgrade? Did the upgrade resolve the issue?** ```sh $ pip install -U git+https://github.com/twopirllc/pandas-ta ``` From 6ee1ea87f2017e305f03bba565d3a79adc7a5b8e Mon Sep 17 00:00:00 2001 From: GFHuang <4510984+GF-Huang@users.noreply.github.com> Date: Mon, 28 Feb 2022 01:24:36 +0800 Subject: [PATCH 2/2] Change `df.ta.to_utc` property to a method Change `df.ta.to_utc` property to a method, because it's not idempotent. See #496 --- pandas_ta/core.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/pandas_ta/core.py b/pandas_ta/core.py index fdee64a..08dc8ac 100644 --- a/pandas_ta/core.py +++ b/pandas_ta/core.py @@ -366,11 +366,6 @@ class AnalysisIndicators(BasePandasObject): else: self._time_range = "years" - @property - def to_utc(self) -> None: - """Sets the DataFrame index to UTC format""" - self._df = to_utc(self._df) - @property def version(self) -> str: """Returns the version.""" @@ -516,6 +511,10 @@ class AnalysisIndicators(BasePandasObject): return name, mode # Public DataFrame Methods + def to_utc(self) -> None: + """Sets the DataFrame index to UTC format""" + self._df = to_utc(self._df) + def constants(self, append: bool, values: list): """Constants