Skip to content

Commit

Permalink
docs: work on installation
Browse files Browse the repository at this point in the history
  • Loading branch information
lars-reimann committed Apr 13, 2024
1 parent 59e894b commit 57de78a
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 11 deletions.
3 changes: 3 additions & 0 deletions docs/getting-started/first-program.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Your First Safe-DS Program

TODO
52 changes: 43 additions & 9 deletions docs/getting-started/installation.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,46 @@
# Installation

1. Get the latest extension for [Visual Studio Code](https://code.visualstudio.com/) from the
[Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=safe-ds.safe-ds). This sets up a
complete _development environment_ for Safe-DS programs.
2. To _execute_ Safe-DS programs, the [Safe-DS Runner](https://github.com/Safe-DS/Runner) has to be installed and
configured additionally:
1. Install [Visual Studio Code](https://code.visualstudio.com/).
2. Install the latest [Safe-DS extension](https://marketplace.visualstudio.com/items?itemName=safe-ds.safe-ds) for
Visual Studio Code to set up a complete development environment for Safe-DS programs.
3. Install the [Safe-DS runner](https://github.com/Safe-DS/Runner) to be able to execute Safe-DS programs:
1. Install [Python](https://www.python.org/) (3.11 or 3.12).
2. Run `pip install "safe-ds-runner>=0.10.0,<0.11.0"` in a command line to download the latest matching Runner version
from [PyPI](https://pypi.org/project/safe-ds-runner/).
3. If the Visual Studio Code extension cannot start the runner, adjust the setting `safe-ds.runner.command`.
Enter the absolute path to the Runner executable.
2. Run `pip install "safe-ds-runner>=0.10.0,<0.11.0"` in a command line to download the latest matching runner
version from [PyPI](https://pypi.org/project/safe-ds-runner/).

## Troubleshooting

### Runner not found

!!! failure "Error Message"

The runner process could not be started: The subprocess could not be started (spawn safe-ds-runner ENOENT).

!!! success "Solution"

1. Make sure, you did the third step of the [installation](#installation) guide correctly.
2. Find your scripts directory by running the following in a command line.
```sh
python -c "import sysconfig; print(sysconfig.get_path('scripts'))"
```

Then, adjust the setting `safe-ds.runner.command` in Visual Studio Code. Enter the absolute path to the runner
executable. Example:

```json
{
"safe-ds.runner.command": "/path/to/venv/bin/safe-ds-runner"
}
```

### Wrong runner version

!!! failure "Error Message"

The installed runner version `0.9.0` is not compatible with this version of the extension.

The installed version should match these requirements: `>=0.10.0,<0.11.0`. Please update to a matching version.

!!! success "Solution"

Run `pip install "safe-ds-runner>=0.10.0,<0.11.0"` in a command line to update the runner.
1 change: 1 addition & 0 deletions docs/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ nav:
- README.md
- Getting Started:
- Installation: getting-started/installation.md
- First Program: getting-started/first-program.md
- Language Reference:
- pipeline-language/README.md
- Files: pipeline-language/files.md
Expand Down
3 changes: 1 addition & 2 deletions docs/pipeline-language/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Language Reference

This part of the documentation provides a detailed reference for the Safe-DS DSL. It is divided into the following
sections:
This part of the documentation provides a detailed reference for the Safe-DS language. It is divided into the following sections:

-

Expand Down

0 comments on commit 57de78a

Please sign in to comment.