diff --git a/.readthedocs.yaml b/.readthedocs.yaml
index d206a3398..fff557735 100644
--- a/.readthedocs.yaml
+++ b/.readthedocs.yaml
@@ -31,14 +31,26 @@ sphinx:
# Optionally set the version of Python and requirements required to build your docs
python:
- version: 3.8
install:
- requirements: requirements.txt
+ - requirements: doc/autodoc_executor_plugins_requirements.txt
- requirements: doc/requirements.txt
- method: pip
path: .
- method: pip
path: .
+ - method: pip
+ path: .
build:
- image: latest
+ os: "ubuntu-22.04"
+ tools:
+ python: "3.8"
+ jobs:
+ # This for dependency pinning because readthedocs.yml automically updates all libraries despite being pinned.
+ # See: https://github.com/readthedocs/readthedocs.org/issues/9752#issuecomment-1324778813
+ post_install:
+ # Botocore from AWS executors requrires urllib3<1.27,>=1.25.4
+ - pip install urllib3==1.26.6
+ # For covalent slurm plugin
+ - pip install aiofiles==0.8.0
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 462aca72a..13792b8ec 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [UNRELEASED]
+### Docs
+
+- Fix autodoc for SSH, Slurm, AWS Braket, AWS Lambda, AWS EC2, AWS Batch, Google Batch
+
### Operations
- Bumped versions in pre-commit config
diff --git a/doc/autodoc_executor_plugins_requirements.txt b/doc/autodoc_executor_plugins_requirements.txt
new file mode 100644
index 000000000..1af017eb5
--- /dev/null
+++ b/doc/autodoc_executor_plugins_requirements.txt
@@ -0,0 +1,7 @@
+covalent-awsbatch-plugin
+covalent-awslambda-plugin
+covalent-braket-plugin
+covalent-ec2-plugin
+covalent-gcpbatch-plugin
+covalent-slurm-plugin
+covalent-ssh-plugin
diff --git a/doc/generate_docs.py b/doc/generate_docs.py
index 8feb0124c..0bed25345 100644
--- a/doc/generate_docs.py
+++ b/doc/generate_docs.py
@@ -20,6 +20,29 @@
import os
import subprocess
+import sys
+
+
+def install_autoclass_doc_dependencies() -> None:
+ """Install the packages required to build the documentation from plugin
+ autoclass."""
+
+ try:
+ # Install covalent from branch source which includes this branch's changes to docs.
+ subprocess.check_call([sys.executable, "-m", "pip", "install", "../"])
+ subprocess.check_call(
+ [
+ sys.executable,
+ "-m",
+ "pip",
+ "install",
+ "-r",
+ "autodoc_executor_plugins_requirements.txt",
+ ]
+ )
+ except subprocess.CalledProcessError as e:
+ print(f"Error handling dependency with error: {e}")
+ sys.exit(1)
def run(clean_dir: bool = False) -> None:
@@ -39,6 +62,7 @@ def run(clean_dir: bool = False) -> None:
print("Removing old build")
cmd = subprocess.Popen(["make", "clean"])
else:
+ install_autoclass_doc_dependencies()
cmd = subprocess.Popen(["make", "html"])
cmd.communicate()
diff --git a/doc/source/api/executors/awsbatch.rst b/doc/source/api/executors/awsbatch.rst
index 3df0855ad..b916793e8 100644
--- a/doc/source/api/executors/awsbatch.rst
+++ b/doc/source/api/executors/awsbatch.rst
@@ -209,11 +209,6 @@ The following shows an example of how a user might modify their `covalent config
...
-.. autoclass:: covalent.executor.EC2Executor
- :members:
- :inherited-members:
-
-
===========================================
4. Required Cloud Resources
===========================================
@@ -355,6 +350,6 @@ In order to run your workflows with covalent there are a few notable AWS resourc
.. 5. Source
.. ===========================================
-.. autoclass:: covalent.executor.AWSBatchExecutor
+.. autoclass:: covalent_awsbatch_plugin.awsbatch.AWSBatchExecutor
:members:
:inherited-members:
diff --git a/doc/source/api/executors/awsbraket.rst b/doc/source/api/executors/awsbraket.rst
index 4848a3e32..e738c96b0 100644
--- a/doc/source/api/executors/awsbraket.rst
+++ b/doc/source/api/executors/awsbraket.rst
@@ -419,6 +419,6 @@ Users can use the following `Terraform `_ snippet as
.. 5. Source
.. ===========================================
-.. autoclass:: covalent.executor.BraketExecutor
+.. autoclass:: covalent_braket_plugin.braket.BraketExecutor
:members:
:inherited-members:
diff --git a/doc/source/api/executors/awslambda.rst b/doc/source/api/executors/awslambda.rst
index fbdf1ae5c..818a19ef8 100644
--- a/doc/source/api/executors/awslambda.rst
+++ b/doc/source/api/executors/awslambda.rst
@@ -454,3 +454,7 @@ Once the derived image has been built and pushed to ECR, users need to create a
--timeout 900
The above CLI command will register a new AWS lambda function that will use the user's custom derived image ``my-custom-lambda-executor:latest`` with a memory size of ``512 MB`` and a timeout values of ``900`` seconds. The ``role`` argument is used to specify the ARN of the IAM role the AWS Lambda can assume during execution. The necessary permissions for the IAM role have been provided in ``Required AWS resources`` section. More details about creating and updating AWS lambda functions can be found `here `_.
+
+.. autoclass:: covalent_awslambda_plugin.AWSLambdaExecutor
+ :members:
+ :inherited-members:
diff --git a/doc/source/api/executors/slurm.rst b/doc/source/api/executors/slurm.rst
index f2858cdd8..e9df75496 100644
--- a/doc/source/api/executors/slurm.rst
+++ b/doc/source/api/executors/slurm.rst
@@ -154,6 +154,6 @@ Then, reinstall this plugin using ``pip install covalent-slurm-plugin[sshproxy]`
The ``hosts`` parameter is a list of hostnames for which the ``sshproxy`` service will be used. If the address provided in the plugin constructor is not present in this list, ``sshproxy`` will not be used. The ``password`` is the user's password, not including the 6-digit OTP. The ``secret`` is the 2FA secret provided when a user registers a new device on `Iris `_. Rather than scan the QR code into an authenticator app, inspect the Oath Seed URL for a string labeled ``secret=...``, typically consisting of numbers and capital letters. Users can validate that correct OTP codes are being generated by using the command ``oathtool `` and using the 6-digit number returned in the "Test" option on the Iris 2FA page. Note that these values are stored in plaintext in the Covalent configuration file. If a user suspects credentials have been stolen or compromised, contact your systems administrator immediately to report the incident and request deactivation.
-.. autoclass:: covalent.executor.SlurmExecutor
+.. autoclass:: covalent_slurm_plugin.SlurmExecutor
:members:
:inherited-members: