From a37d626565930a58a9968965e52c113043fe06bb Mon Sep 17 00:00:00 2001 From: Maarten Pronk <8655030+evetion@users.noreply.github.com> Date: Sun, 11 Feb 2024 16:52:54 +0100 Subject: [PATCH] Clarify that command-line switches need to be manually set in `addprocs` (#50843) Co-authored-by: Max Horn --- doc/src/manual/arrays.md | 2 +- doc/src/manual/distributed-computing.md | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/doc/src/manual/arrays.md b/doc/src/manual/arrays.md index 13b289becf6e0..6aa3a7a724e0e 100644 --- a/doc/src/manual/arrays.md +++ b/doc/src/manual/arrays.md @@ -889,7 +889,7 @@ in their implementations, other arrays — like [`Diagonal`](@ref) — need the full set of cartesian indices to do their lookup (see [`IndexStyle`](@ref) to introspect which is which). -!!! warnings +!!! warning When iterating over all the indices for an array, it is better to iterate over [`eachindex(A)`](@ref) instead of `1:length(A)`. diff --git a/doc/src/manual/distributed-computing.md b/doc/src/manual/distributed-computing.md index e8a2146bdcf3e..020181dd0a08c 100644 --- a/doc/src/manual/distributed-computing.md +++ b/doc/src/manual/distributed-computing.md @@ -270,10 +270,11 @@ julia> addprocs(2) Module [`Distributed`](@ref man-distributed) must be explicitly loaded on the master process before invoking [`addprocs`](@ref). It is automatically made available on the worker processes. -Note that workers do not run a `~/.julia/config/startup.jl` startup script, nor do they synchronize -their global state (such as global variables, new method definitions, and loaded modules) with any -of the other running processes. You may use `addprocs(exeflags="--project")` to initialize a worker with -a particular environment, and then `@everywhere using ` or `@everywhere include("file.jl")`. +!!! note + Note that workers do not run a `~/.julia/config/startup.jl` startup script, nor do they synchronize + their global state (such as command-line switches, global variables, new method definitions, and loaded modules) with any + of the other running processes. You may use `addprocs(exeflags="--project")` to initialize a worker with + a particular environment, and then `@everywhere using ` or `@everywhere include("file.jl")`. Other types of clusters can be supported by writing your own custom `ClusterManager`, as described below in the [ClusterManagers](@ref) section.