The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
Update local script for docs build (#8377)
William FH41524304bf79
diff --git a/docs/.local_build.sh b/docs/.local_build.shindex d5f5fd9184..8b6de50bad 100755--- a/docs/.local_build.sh+++ b/docs/.local_build.sh@@ -13,5 +13,6 @@ cp -r {docs_skeleton,snippets} _distcp -r extras/* _dist/docs_skeleton/docscd _dist/docs_skeletonpoetry run nbdoc_build+poetry run python generate_api_reference_links.pyyarn installyarn startdiff --git a/docs/docs_skeleton/generate_api_reference_links.py b/docs/docs_skeleton/generate_api_reference_links.pyindex da82e17173..3fb97163b2 100644--- a/docs/docs_skeleton/generate_api_reference_links.py+++ b/docs/docs_skeleton/generate_api_reference_links.py@@ -59,6 +59,7 @@ def main():global_imports[class_name][doc_title] = doc_url# Write the global imports information to a JSON file+ _JSON_PATH.parent.mkdir(parents=True, exist_ok=True)with _JSON_PATH.open("w") as f:json.dump(global_imports, f)diff --git a/docs/docs_skeleton/vercel_build.sh b/docs/docs_skeleton/vercel_build.shindex 24ba7de693..1c7e3799d7 100755--- a/docs/docs_skeleton/vercel_build.sh+++ b/docs/docs_skeleton/vercel_build.sh@@ -1,26 +1,47 @@#!/bin/bash+version_compare() {+ local v1=(${1//./ })+ local v2=(${2//./ })+ for i in {0..2}; do+ if (( ${v1[i]} < ${v2[i]} )); then+ return 1+ fi+ done+ return 0+}++openssl_version=$(openssl version | awk '{print $2}')+required_openssl_version="1.1.1"++python_version=$(python3 --version 2>&1 | awk '{print $2}')+required_python_version="3.10"++echo "OpenSSL Version"+echo $openssl_version+echo "Python Version"+echo $python_version+# If openssl version is less than 1.1.1 AND python version is less than 3.10+if ! version_compare $openssl_version $required_openssl_version && ! version_compare $python_version $required_python_version; then### See: https://github.com/urllib3/urllib3/issues/2168# Requests lib breaks for old SSL versions,# which are defaults on Amazon Linux 2 (which Vercel uses for builds)-yum -y update-yum remove openssl-devel -y-yum install gcc bzip2-devel libffi-devel zlib-devel wget tar -y-yum install openssl11 -y-yum install openssl11-devel -y-# Install python 3.11 to connect with openSSL 1.1.1-wget https://www.python.org/ftp/python/3.11.4/Python-3.11.4.tgz-tar xzf Python-3.11.4.tgz-cd Python-3.11.4-./configure-make altinstall-# Check python version-echo "Python Version"-python3.11 --version-cd ..-###+ yum -y update+ yum remove openssl-devel -y+ yum install gcc bzip2-devel libffi-devel zlib-devel wget tar -y+ yum install openssl11 -y+ yum install openssl11-devel -y++ wget https://www.python.org/ftp/python/3.11.4/Python-3.11.4.tgz+ tar xzf Python-3.11.4.tgz+ cd Python-3.11.4+ ./configure+ make altinstall+ echo "Python Version"+ python3.11 --version+ cd ..+fi-# Install nbdev and generate docscd ..python3.11 -m venv .venvsource .venv/bin/activate