The instructions on this page are meant for library contributors. If you are interested in contributing to this project, read on. Otherwise, if you are simply wanting to get EarningsCalls Transcripts or Audio Files, please read the README page to get started.
First, install Hatch plus other build dependencies. See the Hatch installation instructions.
My preferred way to install it is to use pip:
pip install hatch hatch-containers coverage black responseshatch buildhatch run testhatch run covOr, generate HTML report locally:
coverage htmlThe container tests are run in GitHub Actions. Normally, you don't need to run them locally.
The container tests run all unit tests in a containerized environment.
Each environment is a different Python version.
hatch run all:testhatch run lint:allIf you get linter errors, you can automatically fix them by running this command:
hatch run lint:fmtYou can use the following test code to save responses from the server as a .YAML file:
import requests
from responses import _recorder
@_recorder.record(file_path="symbols.yaml")
def test_save_symbols_v1():
requests.get("https://earningscall.biz/symbols.txt")
@_recorder.record(file_path="symbols-v2.yaml")
def test_save_symbols_v1():
requests.get("https://earningscall.biz/symbols-v2.txt")Assuming you want to publish version 0.0.7, first, make your changes, then run the commands:
git commit -a
git tag v0.0.7
git push --atomic origin master v0.0.7Use the library to get a single transcript from the API:
python -m scripts.get_single_transcriptGet all transcripts for a company:
python -m scripts.get_all_company_transcriptsList all companies:
python -m scripts.list_companies