From d8767b811062420f9dba416deb59f947e1608a95 Mon Sep 17 00:00:00 2001 From: Mohamed Koubaa Date: Wed, 13 Nov 2024 06:59:14 -0600 Subject: [PATCH 1/3] add devcontainer --- .devcontainer/devcontainer.json | 40 +++++++++++++++++++++++++++++++++ .devcontainer/welcome.rst | 5 +++++ tests/test_perf.py | 2 +- 3 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 .devcontainer/devcontainer.json create mode 100644 .devcontainer/welcome.rst diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 000000000..64a900299 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,40 @@ +// For format details, see https://aka.ms/devcontainer.json. For config options, see the +// README at: https://github.com/devcontainers/templates/tree/main/src/python +{ + "name": "Python 3", + // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile + "image": "mcr.microsoft.com/devcontainers/python:1-3.12-bullseye", + + // Features to add to the dev container. More info: https://containers.dev/features. + // "features": {}, + + // Use 'forwardPorts' to make a list of ports inside the container available locally. + // "forwardPorts": [], + + // Use 'postCreateCommand' to run commands after the container is created. + "postCreateCommand": "echo 'Installing dependencies...' && pip3 install -e '.[doc,test,codegen,viz,post]' && pip3 install pre-commit && pre-commit install --install-hooks", + + // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. + // "remoteUser": "root" + + // Configure tool-specific properties. + "customizations": { + // Configure properties specific to VSCode. + "vscode": { + "openFiles": [ + ".devcontainer/welcome.rst" + ], + "extensions": [ + "ms-python.python" + ], + "settings": { + "terminal.integrated.defaultProfile.linux": "bash", + "python.testing.pytestArgs": [ + "tests" + ], + "python.testing.unittestEnabled": false, + "python.testing.pytestEnabled": true + } + } + } +} diff --git a/.devcontainer/welcome.rst b/.devcontainer/welcome.rst new file mode 100644 index 000000000..288de0b54 --- /dev/null +++ b/.devcontainer/welcome.rst @@ -0,0 +1,5 @@ +Welcome to VSCode DevContainer! +=============================== + +This Devcontainer has been specifically set for developing and/or documenting Dynalib. + diff --git a/tests/test_perf.py b/tests/test_perf.py index b52569697..190f4ee6e 100644 --- a/tests/test_perf.py +++ b/tests/test_perf.py @@ -45,7 +45,7 @@ def _gen_nodes(count): def write1(s: io.StringIO, nodes: kwd.Node): - """Write the keyword with the implementation that is built into dynalib""" + """Write the keyword with the implementation that is built into PyDyna.""" nodes.write(s) return s From 2ec5b958f0c3f7356074721d568dd15a5f0d12be Mon Sep 17 00:00:00 2001 From: Mohamed Koubaa Date: Wed, 13 Nov 2024 07:20:35 -0600 Subject: [PATCH 2/3] Update .devcontainer/welcome.rst Co-authored-by: Revathy Venugopal <104772255+Revathyvenugopal162@users.noreply.github.com> --- .devcontainer/welcome.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/welcome.rst b/.devcontainer/welcome.rst index 288de0b54..70403f3c9 100644 --- a/.devcontainer/welcome.rst +++ b/.devcontainer/welcome.rst @@ -1,5 +1,5 @@ Welcome to VSCode DevContainer! =============================== -This Devcontainer has been specifically set for developing and/or documenting Dynalib. +This Devcontainer has been specifically set for developing and/or documenting PyDyna. From 8725b3855a4022110f4e7b74e819b52243bfae5b Mon Sep 17 00:00:00 2001 From: Mohamed Koubaa Date: Wed, 13 Nov 2024 07:25:52 -0600 Subject: [PATCH 3/3] update requirements --- .devcontainer/devcontainer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 64a900299..56a2d66fd 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -12,7 +12,7 @@ // "forwardPorts": [], // Use 'postCreateCommand' to run commands after the container is created. - "postCreateCommand": "echo 'Installing dependencies...' && pip3 install -e '.[doc,test,codegen,viz,post]' && pip3 install pre-commit && pre-commit install --install-hooks", + "postCreateCommand": "echo 'Installing dependencies...' && pip3 install -e '.[test,codegen]' && pip3 install pre-commit && pre-commit install --install-hooks", // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. // "remoteUser": "root"