You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/developing/compatibility.md
+88-1Lines changed: 88 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -136,7 +136,7 @@ build config | image version
136
136
---|---
137
137
default | >= v4.0.0
138
138
139
-
### >= 4.3.1
139
+
### >= 4.3.1, < v4.4.13
140
140
One release after getting development to function with ldmx/dev:v5,
141
141
I (Tom) accidentally introduced a change that breaks compatibility with ldmx/dev:4.2.2
142
142
which uses an older version of ROOT.
@@ -158,3 +158,90 @@ build config | image version
158
158
---|---
159
159
default | >= v5.0.0
160
160
include lorentz vector | >= v4.0.0
161
+
162
+
### >= v4.4.13
163
+
Some changes were made to how the environment in the development container is configured so
164
+
that the denv workspace can be moved into ldmx-sw [ldmx-sw #1472](https://github.com/LDMX-Software/ldmx-sw/issues/1472).
165
+
This leads to a set of confusing warnings and errors that are difficult for a non-expert to understand.
166
+
167
+
The main source of this is that `denv` relies on copying a shell configuration file called `.profile` into your workspace and then reading that configuration file when launching the container.
168
+
This `.profile` allows you to [customize your container environment](https://tomeichlersmith.github.io/denv/tune.html#rc-files), but it also is _never_ overwritten by `denv` in order to avoid undoing any changes you want to make.
169
+
170
+
If you don't care about customizing your local container environment (e.g. you've never looked at the `.profile` before), then you can just remove it and have `denv` make a new copy whenever you switch images.
171
+
```
172
+
rm .denv/skel-init .bashrc .bash_logout .profile
173
+
denv config image <pull-or-different-tag>
174
+
```
175
+
176
+
If you do care about keeping your local customizations,
177
+
I've written some notes on changes that I suspect you need to make to `.profile` depending on
178
+
the error message you are seeing.
179
+
180
+
You can find the `.profile` that `denv` is using within your denv workspace by running `denv printenv HOME`
181
+
which will print the directory in which the `.profile` will be.
182
+
183
+
~~~admonish note title="Neither `LDMX_BASE` nor `LDMX_SW_INSTALL` is defined." collapsible=true
184
+
This comes from having a `.profile` file from an image >= v5.1.1 being used with an older image <= v5.1.0
185
+
that expects a different `.profile`.
186
+
187
+
Inside the `.profile`, make sure to define `LDMX_SW_INSTALL` _before_ the `. /etc/ldmx-env-init.sh` line.
188
+
189
+
If ldmx-sw is the denv workspace, then you should define
190
+
```
191
+
export LDMX_SW_INSTALL=${HOME}/install
192
+
```
193
+
or if the parent directory of ldmx-sw is the denv workspace, then
194
+
```
195
+
export LDMX_SW_INSTALL=${HOME}/ldmx-sw/install
196
+
```
197
+
or you can set it to some other path that you are installing ldmx-sw to.
198
+
~~~
199
+
200
+
~~~admonish note title="fire: command not found" collapsible=true
201
+
This arises from a lot of different combinations of `.profile` files and image versions,
202
+
but it simplifies once you know a little of the background.
203
+
Most of the time it comes up because you have an old (<= v5.1.0) `.profile` being used
204
+
with a new (>= v5.1.1) image.
205
+
206
+
The shell within the container looks through the directories in a `:`-separated list
207
+
stored in the `PATH` environment variable, so this error crops up if the `PATH` variable
208
+
is not configured properly.
209
+
210
+
You can use `denv printenv PATH` to see where the shell is looking for executables.
211
+
You want to leave the `/usr/...` ones as written (those are the ones for stuff in the image),
212
+
but the other one refers to a directory that is supposed to be on your system and point to
213
+
where ldmx-sw is installed.
214
+
215
+
For example, you may need to remove the `LDMX_BASE` lines from within the `.profile` file in your denv
216
+
workspace. Notice that before I edited `.profile` with `vim`, there is an extra "ldmx-sw" in the path to its
0 commit comments