diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index e9e61dfe550..1a881ba6d7a 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -95,6 +95,8 @@ jobs: pip list - name: Run tests (Bash) + env: + MPLBACKEND: Agg shell: bash -l {0} run: pytest tests/ -m "not bots and not linux" diff --git a/build/nsis/setup.nsi b/build/nsis/setup.nsi index cd64819a917..0ce5eb47e1c 100644 --- a/build/nsis/setup.nsi +++ b/build/nsis/setup.nsi @@ -3,26 +3,26 @@ !include "MUI2.nsh" !include "logiclib.nsh" - - + + ;-------------------------------- ; Custom defines !define NAME "OpenBB Terminal" !define COMPANY "OpenBB" !define APPFILE "OpenBBTerminal.exe" - !define VERSION "1.2.0" + !define VERSION "1.6.0" !define SLUG "${NAME} v${VERSION}" - + ;-------------------------------- ; General Name "${NAME}" OutFile "${NAME} Setup.exe" InstallDir $PROFILE\OpenBB RequestExecutionLevel user - + ;-------------------------------- ; UI - + !define MUI_ICON "assets\openbb_icon.ico" !define MUI_UNICON "assets\openbb_icon.ico" !define MUI_HEADERIMAGE @@ -30,10 +30,10 @@ !define MUI_HEADERIMAGE_BITMAP "assets\installer_horizontal.bmp" !define MUI_ABORTWARNING !define MUI_WELCOMEPAGE_TITLE "${SLUG} Setup" - + ;-------------------------------- ; Pages - + ; Installer pages !insertmacro MUI_PAGE_WELCOME !insertmacro MUI_PAGE_LICENSE "license.txt" @@ -45,22 +45,22 @@ ; Uninstaller pages !insertmacro MUI_UNPAGE_CONFIRM !insertmacro MUI_UNPAGE_INSTFILES - + ; Set UI language !insertmacro MUI_LANGUAGE "English" - + ;-------------------------------- ; Section - Install App Section "-hidden app" SectionIn RO SetOutPath "$INSTDIR" - File /r "app\*.*" + File /r "app\*.*" WriteRegStr HKCU "Software\${NAME}" "" $INSTDIR WriteUninstaller "$INSTDIR\Uninstall.exe" SectionEnd - + ;-------------------------------- ; Section - Shortcut @@ -70,8 +70,8 @@ CreateShortCut '$SMPROGRAMS\${Company}\${NAME}\${NAME}.lnk' '$INSTDIR\${APPFILE}' "" '$INSTDIR\${APPFILE}' 0 CreateShortCut '$SMPROGRAMS\${Company}\${NAME}\Uninstall ${NAME}.lnk' '$INSTDIR\Uninstall.exe' "" '$INSTDIR\Uninstall.exe' 0 SectionEnd - - + + ;-------------------------------- ; Remove empty parent directories @@ -97,7 +97,7 @@ Pop $0 FunctionEnd - + ;-------------------------------- ; Section - Uninstaller @@ -105,7 +105,7 @@ Section "Uninstall" ;Delete Shortcut Delete "$DESKTOP\${NAME}.lnk" - + ;Delete Directory Delete '$SMPROGRAMS\${Company}\${NAME}' @@ -118,4 +118,4 @@ Section "Uninstall" DeleteRegKey /ifempty HKCU "Software\${NAME}" -SectionEnd \ No newline at end of file +SectionEnd diff --git a/build/pyinstaller/.env b/build/pyinstaller/.env index c95457a3909..047a8413d36 100644 --- a/build/pyinstaller/.env +++ b/build/pyinstaller/.env @@ -1,5 +1,5 @@ OPENBB_PACKAGED_APPLICATION=true -OPENBB_LOGGING_COMMIT_HASH='sha:aabb76ef' +OPENBB_LOGGING_COMMIT_HASH='sha:dd768556' OPENBB_ENABLE_PREDICT=true OPENBB_ENABLE_CHECK_API=true OPENBB_ENABLE_THOUGHTS_DAY=false diff --git a/build/pyinstaller/terminal.spec b/build/pyinstaller/terminal.spec index 1b3ba0ed7a6..22b83f0452a 100644 --- a/build/pyinstaller/terminal.spec +++ b/build/pyinstaller/terminal.spec @@ -28,6 +28,7 @@ set_key(default_env_file, "OPENBB_LOGGING_COMMIT_HASH", str(commit_hash)) # Files that are explicitly pulled into the bundle added_files = [ (os.path.join(os.getcwd(), "openbb_terminal"), "openbb_terminal"), + (os.path.join(os.getcwd(), "data_sources_default.json"), "."), (os.path.join(os.getcwd(), "routines"), "routines"), (os.path.join(os.getcwd(), "portfolio"), "portfolio"), (os.path.join(os.getcwd(), "i18n"), "i18n"), diff --git a/openbb_terminal/cryptocurrency/overview/withdrawalfees_model.py b/openbb_terminal/cryptocurrency/overview/withdrawalfees_model.py index 541fbeda3e4..188996d9190 100644 --- a/openbb_terminal/cryptocurrency/overview/withdrawalfees_model.py +++ b/openbb_terminal/cryptocurrency/overview/withdrawalfees_model.py @@ -146,7 +146,7 @@ def get_overall_withdrawal_fees(top: int = 100) -> pd.DataFrame: df = pd.read_html(str(table))[0] df["Coin"] = [ticker.text for ticker in tickers_html] - df["Highest"] = df["Highest"].apply( + df["Lowest"] = df["Lowest"].apply( lambda x: f'{x[:x.index(".")+3]} ({x[x.index(".")+3:]})' if "." in x and isinstance(x, str) else x diff --git a/openbb_terminal/feature_flags.py b/openbb_terminal/feature_flags.py index a7589fd4ade..35a05ba99fa 100644 --- a/openbb_terminal/feature_flags.py +++ b/openbb_terminal/feature_flags.py @@ -106,7 +106,11 @@ LOGGING_COMMIT_HASH = str(os.getenv("OPENBB_LOGGING_COMMIT_HASH", "REPLACE_ME")) PREFERRED_DATA_SOURCE_FILE = str( os.getenv( "OPENBB_PREFERRED_DATA_SOURCE_FILE", - os.getcwd() + os.path.sep + "data_sources_default.json", + os.path.join( + os.path.dirname(os.path.abspath(__file__)), + "..", + "data_sources_default.json", + ), ) ) @@ -121,5 +125,5 @@ GUESS_EASTER_EGG_FILE = str( try: version = pkg_resources.get_distribution("OpenBBTerminal").version except Exception: - version = "1.5.0m" + version = "1.6.0m" VERSION = str(os.getenv("OPENBB_VERSION", version)) diff --git a/openbb_terminal/sources_controller.py b/openbb_terminal/sources_controller.py index 78fb78fe36a..d5ab4c4a194 100644 --- a/openbb_terminal/sources_controller.py +++ b/openbb_terminal/sources_controller.py @@ -43,7 +43,7 @@ class SourcesController(BaseController): super().__init__(queue) self.commands_with_sources = dict() - with open("data_sources_default.json") as f: + with open(obbff.PREFERRED_DATA_SOURCE_FILE) as f: self.json_doc = json.load(f) for context in self.json_doc: for menu in self.json_doc[context]: diff --git a/pyproject.toml b/pyproject.toml index 70185a6a5c9..79d6d791392 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ # https://python-poetry.org/docs/dependency-specification/ [tool.poetry] name = "OpenBBTerminal" -version = "1.5.0" +version = "1.6.0" description = "" authors = ["Didier Rodrigues Lopes"] packages = [ diff --git a/scripts/test_crypto_defi.openbb b/scripts/test_crypto_defi.openbb index b6506d9e095..01b123b6997 100644 --- a/scripts/test_crypto_defi.openbb +++ b/scripts/test_crypto_defi.openbb @@ -3,12 +3,8 @@ defi ldapps gdapps stvl -dtvl anchor,sushiswap newsletter dpi -funding -borrow -lending tokens stats pools diff --git a/scripts/test_stocks_dps.openbb b/scripts/test_stocks_dps.openbb index 15cd702b7e3..f96d629ec07 100644 --- a/scripts/test_stocks_dps.openbb +++ b/scripts/test_stocks_dps.openbb @@ -5,10 +5,6 @@ hsi pos sidtc load -t gme -dpotc spos psi -volexch -ftd -prom -exit \ No newline at end of file +exit