This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def _markdown_to_pdf_anvil(self, markdown_text: str, company_name: str) -> bytes: | |
"""Convert markdown to PDF using Anvil API.""" | |
# Ensure Anvil is available before proceeding | |
if not ANVIL_AVAILABLE or Anvil is None: | |
raise RuntimeError("Anvil API is not available") | |
try: | |
# Get API key from instance or environment | |
api_key = self.anvil_api_key | |
if not api_key: |