Describe the bug
When changing the "Location of your images" setting, if there are images in both the old and new directories, Pharo Launcher attempts to warn that you'll need to manually migrate/merge them. But this now fails due to a change in Spec a while back, introducing the concept of a command "context" that must be set in order to retrieve things like the active "application". Since many commands only access the application in an exceptional path, to notify the user of something for instance, it's easy for this to get missed. And it's not always easy or clear to figure out what the correct context should be.
To Reproduce
Have at least one image in the currently-configured image directory.
Copy at least one image to another directory (call it the "new directory").
Open Settings in Pharo Launcher and attempt to change the "Location of your images" setting to the new directory.
See #application was sent to nil error.
Expected behavior
A notification that images must be manually copied, then the setting to be successfully changed.
Version information: Any OS, Pharo Launcher 3.0.1
Expected development cost
I fixed something like this in Iceberg a while back...it took a lot of hemming and hawing until I figured out that some other commands already established a clear pattern to follow, then was easy. I don't see an obvious place to get the context from in this case, but once that's established it's not that much code to change.
Describe the bug When changing the "Location of your images" setting, if there are images in both the old and new directories, Pharo Launcher attempts to warn that you'll need to manually migrate/merge them. But this now fails due to a change in Spec a while back, introducing the concept of a command "context" that must be set in order to retrieve things like the active "application". Since many commands only access the application in an exceptional path, to notify the user of something for instance, it's easy for this to get missed. And it's not always easy or clear to figure out what the correct context should be.
To Reproduce
#application was sent to nil
error.Expected behavior A notification that images must be manually copied, then the setting to be successfully changed.
Version information: Any OS, Pharo Launcher 3.0.1
Expected development cost I fixed something like this in Iceberg a while back...it took a lot of hemming and hawing until I figured out that some other commands already established a clear pattern to follow, then was easy. I don't see an obvious place to get the context from in this case, but once that's established it's not that much code to change.