photoprism / photoprism

AI-Powered Photos App for the Decentralized Web 🌈💎✨
https://www.photoprism.app
Other
35.27k stars 1.94k forks source link

cant find settings.yml #418

Closed ankye closed 4 years ago

ankye commented 4 years ago

git pull develop or master ,make success,but cant' run , show cant find settings.yml,where can get the settings.yml

lastzero commented 4 years ago

Will be created automatically when you save settings for the first time, or check the config package test data for examples.

lastzero commented 4 years ago

Settings are not required to start the server! This is NOT the reason if you have problems.

ghost commented 4 years ago

Go version is 1.14.4 OS is nixos 20.03

I have the same issue. /var/lib/private/photoprism exists, and permissions is not the issue. I get this running as a regular user, as root, as a dynamic user in a systemd service.

Even if I make storage/settings/ manually I get the same error.

If I run as my own user, in the build directory ./photoprism start, I get the same issue.

level=info msg="settings file not found: /var/lib/private/photoprism/storage/settings/settings.yml"
level=debug msg="mkdir : no such file or directory"
level=error msg="can't create : please check configuration and permissions"
level=info msg="settings file not found: /var/lib/private/photoprism/storage/ettings/settings.yml"
level=info msg="looking for pid in /var/lib/private/photoprism/storage/photoprism.pid"
level=fatal msg="open /var/lib/private/photoprism/storage/photoprism.pid: no such file or directory"
[Unit]
Description=PhotoPrism

[Service]
Environment="HOME=/var/lib/private/photoprism"
Environment="LOCALE_ARCHIVE=/nix/store/zcsy6v9ivwld6h4i1aqggn0zfk602dls-glibc-locales-2.30/lib/locale/locale-archive"
Environment="PATH=/nix/store/v8v81amvwqf73m6mkg5vgijq4gjkpvg3-libtensorflow-1.14.0/bin:/nix/store/x0jla3hpxrwz76hy9yckg1iyc9hns81k-cor...
Environment="PHOTOPRISM_ADMIN_PASSWORD=photoprism"
Environment="PHOTOPRISM_DARKTABLE_PRESETS=false"
Environment="PHOTOPRISM_DATABASE_DRIVER=sqlite"
Environment="PHOTOPRISM_DEBUG=true"
Environment="PHOTOPRISM_DETECT_NSFW=false"
Environment="PHOTOPRISM_EXPERIMENTAL=false"
Environment="PHOTOPRISM_HTTP_HOST=127.0.0.1"
Environment="PHOTOPRISM_HTTP_PORT=2342"
Environment="PHOTOPRISM_JPEG_QUALITY=90"
Environment="PHOTOPRISM_JPEG_SIZE=7680"
Environment="PHOTOPRISM_PUBLIC=false"
Environment="PHOTOPRISM_READONLY=false"
Environment="PHOTOPRISM_SETTINGS_HIDDEN=false"
Environment="PHOTOPRISM_SITE_AUTHOR="
Environment="PHOTOPRISM_SITE_CAPTION=Browse Your Life"
Environment="PHOTOPRISM_SITE_DESCRIPTION="
Environment="PHOTOPRISM_SITE_TITLE=PhotoPrism"
Environment="PHOTOPRISM_SITE_URL=http://localhost:2342/"
Environment="PHOTOPRISM_STORAGE_PATH=/var/lib/private/photoprism/storage"
Environment="PHOTOPRISM_THUMB_FILTER=lanczos"
Environment="PHOTOPRISM_THUMB_SIZE=2048"
Environment="PHOTOPRISM_THUMB_SIZE_UNCACHED=7680"
Environment="PHOTOPRISM_THUMB_UNCACHED=false"
Environment="PHOTOPRISM_UPLOAD_NSFW=true"
Environment="TZDIR=/nix/store/8cz89zavyrm2bdrgkx4l66s5c7nx12dr-tzdata-2019c/share/zoneinfo"

DynamicUser=yes
ExecStart=/etc/nixos/bin/photoprism start
ExecStop=/etc/nixos/bin/photoprism stop
ReadWritePaths=/var/lib/private/photoprism
Restart=always
RestartSec=10
StateDirectory=photoprism
Type=simple
WorkingDirectory=/var/lib/private/photoprism
lastzero commented 4 years ago

Run photoprism config and check if any paths don't exist or might cause issues. The settings file is not required, it's just an info if you look closely.

Or simply use our pre-built Docker image which contains everything you need e.g. TensorFlow, which is typically missing if you compile photoprism from source.

ghost commented 4 years ago

Ignoring running as a service.

If I run the file after building from source as my own user, all the locations are within my home folder. This is MkdirAll throwing the error mkdir : no such file or directory. My home directory very much exists. All the paths printed with photoprism config are under my home folder.

I tried a few things I suspected like switching from the hardened linux kernel to the standard. Ensuring apparmor was not used, etc.

If I create /home/paul/photoprism/.photoprism/storage/settings/ using mkdir on the command line the error changes to:

INFO[2020-07-25T10:30:10Z] settings file not found: /home/paul/photoprism/.photoprism/storage/settings/settings.yml
ERRO[2020-07-25T10:30:10Z] can't create : please check configuration and permissions

So this very much seems like a permission issue where the system call can not write to this directory for some odd reason.

I do not like docker. This has nothing to do with the tensorflow lib, it is in the environment of the executable on my system.

lastzero commented 4 years ago

Did you run make install?

ghost commented 4 years ago

Using

[nix-shell:~/photoprism]$ make install
scripts/build.sh prod ~/.local/bin/photoprism
Building production binary...
30M     /home/paul/.local/bin/photoprism
Done.
Installing assets
mkdir -p ~/.photoprism/storage/settings
mkdir -p ~/.photoprism/storage/cache
mkdir -p ~/.photoprism/storage
mkdir -p ~/.photoprism/assets
mkdir -p ~/Pictures/Originals
mkdir -p ~/Pictures/Import
cp -r assets/static assets/templates assets/nasnet assets/nsfw ~/.photoprism/assets
find ~/.photoprism/assets -name '.*' -type f -delete
[nix-shell:~/photoprism]$ photoprism start

INFO[2020-07-25T10:44:51Z] settings file not found: /home/paul/.photoprism/storage/settings/settings.yml
ERRO[2020-07-25T10:44:51Z] can't create : please check configuration and permissions

The error is coming from internal/config/filenames.go line 38.

lastzero commented 4 years ago

I assume you ran make all before? On vacation right now, taking a few days off. I'll take a look as soon as possible. Our CI tests don't report installation errors, so I guess this can be fixed easily.

lastzero commented 4 years ago

PS: TensorFlow was just an example, there are other dependencies too and it is more difficult to upgrade. You should only install this manually if you absolutely know what you are getting yourself into. Ideally you can also debug issues like this on your own and send a pull request with a fix if necessary until we are able to provide tested deb or RPM packages for users who don't like Docker.

ghost commented 4 years ago

Yeah make all was run before.

I gave it a little look before and I saw no obvious reason for the error.

I could look into making a reproducible environment for it, but I have to go to work now, and you are on vacation.

lastzero commented 4 years ago

Any news on this?

ghost commented 4 years ago

It is something I want to figure out/resolve eventually. Right now I deployed it using podman.

ghost commented 4 years ago

Running photoprism start with strace

newfstatat(AT_FDCWD, "/photoprism/photos/originals", 0xc013644108, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/photoprism/storage/originals", 0xc0136441d8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/photoprism/originals", 0xc0136442a8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/PhotoPrism/Originals", 0xc013644788, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/PhotoPrism/Original", 0xc013644c68, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/pictures/originals", 0xc013644ed8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Pictures/Originals", 0xc013645148, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/pictures/original", 0xc0136453b8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Pictures/Original", 0xc013645628, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/photos/originals", 0xc013645898, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Photos/Originals", 0xc013645b08, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/storage/originals", 0xc013645d78, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/photos/original", 0xc013646038, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Photos/Original", 0xc0136462a8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/originals", 0xc013646518, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Originals", 0xc013646788, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/original", 0xc0136469f8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Original", 0xc013646c68, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/pictures", 0xc013646ed8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Pictures", 0xc013647148, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/photos", 0xc0136473b8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Photos", 0xc013647628, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/images", 0xc013647898, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Images", 0xc013647b08, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/bilder", 0xc013647d78, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Bilder", 0xc013648038, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/fotos", 0xc0136482a8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/Fotos", 0xc013648518, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/originals", 0xc0136485e8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/PhotoPrism/Originals", 0xc0136486b8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/photoprism/original", 0xc013648788, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/PhotoPrism/Original", 0xc013648858, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/pictures/originals", 0xc013648928, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/Pictures/Originals/.photoprism/storage", 0xc013648c68, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/home/paul/.photoprism/storage/settings/settings.yml", 0xc013648ed8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "locales/en/LC_MESSAGES/default.po", 0xc013648fa8, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "locales/en/default.po", 0xc013649078, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "locales/en/LC_MESSAGES/default.mo", 0xc013649148, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "locales/en/default.mo", 0xc013649218, 0) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "", 0xc0136492e8, 0) = -1 ENOENT (No such file or directory)
mkdirat(AT_FDCWD, "", 0777)             = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "", 0xc0136493b8, AT_SYMLINK_NOFOLLOW) = -1 ENOENT (No such file or directory)

I think the error is coming from this syscall

mkdirat(AT_FDCWD, "", 0777)             = -1 ENOENT (No such file or directory)

Which would explain why the error is:

result = fmt.Errorf("can't create %s: please check configuration and permissions", txt.Quote(path))
can't create : please check configuration and permissions

If I marshal the params struct and run photoprism start

{
  "Name": "PhotoPrism",
  "Version": "200818-6e2849fb-Linux-unknown",
  "Copyright": "(c) 2018-2020 Michael Mayer <hello@photoprism.org>",
  "SiteUrl": "http://localhost:2342/",
  "SitePreview": "",
  "SiteTitle": "PhotoPrism",
  "SiteCaption": "Browse Your Life",
  "SiteDescription": "",
  "SiteAuthor": "",
  "Public": false,
  "Debug": false,
  "ReadOnly": false,
  "Experimental": false,
  "TensorFlowOff": false,
  "Workers": 0,
  "WakeupInterval": 0,
  "AdminPassword": "",
  "LogLevel": "info",
  "AssetsPath": "",
  "StoragePath": "",
  "ImportPath": "",
  "OriginalsPath": "/home/paul/Pictures/Originals",
  "OriginalsLimit": 1000,
  "ConfigFile": "",
  "SettingsPath": "",
  "SettingsHidden": false,
  "TempPath": "",
  "CachePath": "",
  "DatabaseDriver": "sqlite",
  "DatabaseDsn": "",
  "DatabaseConns": 0,
  "DatabaseConnsIdle": 0,
  "HttpServerHost": "",
  "HttpServerPort": 2342,
  "HttpServerMode": "",
  "HttpServerPassword": "",
  "SipsBin": "sips",
  "RawtherapeeBin": "rawtherapee-cli",
  "DarktableBin": "darktable-cli",
  "DarktablePresets": false,
  "HeifConvertBin": "heif-convert",
  "FFmpegBin": "ffmpeg",
  "ExifToolBin": "exiftool",
  "SidecarJson": false,
  "SidecarYaml": false,
  "SidecarPath": "",
  "PIDFilename": "",
  "LogFilename": "",
  "DetachServer": false,
  "DetectNSFW": false,
  "UploadNSFW": false,
  "GeoCodingApi": "places",
  "DownloadToken": "",
  "PreviewToken": "public",
  "ThumbFilter": "lanczos",
  "ThumbUncached": false,
  "ThumbSize": 2048,
  "ThumbSizeUncached": 7680,
  "JpegSize": 7680,
  "JpegQuality": 92
}

Which I am going to guess is because of the original level=info msg="settings file not found: /var/lib/private/photoprism/storage/settings/settings.yml"

Okay so if I run this now in an environment of

PHOTOPRISM_HTTP_HOST=127.0.0.1
LANG=en_US.UTF-8
PHOTOPRISM_SITE_TITLE=PhotoPrism
INVOCATION_ID=476806c2da204f259d657b84966a4b57
PHOTOPRISM_SITE_CAPTION=Browse Your Life
PHOTOPRISM_SITE_DESCRIPTION=
PHOTOPRISM_ADMIN_PASSWORD=photoprism
USER=photoprism
PHOTOPRISM_SETTINGS_HIDDEN=false
PHOTOPRISM_PUBLIC=false
TZDIR=/nix/store/8cz89zavyrm2bdrgkx4l66s5c7nx12dr-tzdata-2019c/share/zoneinfo
PWD=/var/lib/photoprism
HOME=/var/lib/photoprism
JOURNAL_STREAM=8:8445783
PHOTOPRISM_THUMB_SIZE_UNCACHED=7680
PHOTOPRISM_THUMB_FILTER=lanczos
PHOTOPRISM_THUMB_UNCACHED=false
PHOTOPRISM_DETECT_NSFW=false
PHOTOPRISM_DARKTABLE_PRESETS=false
PHOTOPRISM_STORAGE_PATH=/var/lib/photoprism/storage
PHOTOPRISM_JPEG_SIZE=7680
SHELL=/run/current-system/sw/bin/bash
PHOTOPRISM_HTTP_PORT=2342
PHOTOPRISM_SITE_URL=http://localhost:2342/
PHOTOPRISM_READONLY=false
STATE_DIRECTORY=/var/lib/photoprism
PHOTOPRISM_UPLOAD_NSFW=true
SHLVL=1
LOCALE_ARCHIVE=/nix/store/j9kgy904wivc8kbc2dwgaihcbmh9v6ny-glibc-locales-2.31/lib/lo>
LOGNAME=photoprism
PHOTOPRISM_DEBUG=true
PHOTOPRISM_THUMB_SIZE=2048
PATH=/nix/store/cc64vcf0g3l5ck0c5pfwflcacb8x7i4d-coreutils-8.31/bin:/nix/store/kb6i8>
PHOTOPRISM_JPEG_QUALITY=90
PHOTOPRISM_EXPERIMENTAL=false
PHOTOPRISM_DATABASE_DRIVER=sqlite
PHOTOPRISM_SITE_AUTHOR=

I get

{
  "Name": "PhotoPrism",
  "Version": "200818-6e2849fb-Linux-unknown",
  "Copyright": "(c) 2018-2020 Michael Mayer <hello@photoprism.org>",
  "SiteUrl": "http://localhost:2342/",
  "SitePreview": "",
  "SiteTitle": "PhotoPrism",
  "SiteCaption": "Browse Your Life",
  "SiteDescription": "",
  "SiteAuthor": "",
  "Public": false,
  "Debug": true,
  "ReadOnly": false,
  "Experimental": false,
  "TensorFlowOff": false,
  "Workers": 0,
  "WakeupInterval": 0,
  "AdminPassword": "photoprism",
  "LogLevel": "info",
  "AssetsPath": "",
  "StoragePath": "/var/lib/photoprism/storage",
  "ImportPath": "",
  "OriginalsPath": "",
  "OriginalsLimit": 1000,
  "ConfigFile": "",
  "SettingsPath": "",
  "SettingsHidden": false,
  "TempPath": "",
  "CachePath": "",
  "DatabaseDriver": "sqlite",
  "DatabaseDsn": "",
  "DatabaseConns": 0,
  "DatabaseConnsIdle": 0,
  "HttpServerHost": "127.0.0.1",
  "HttpServerPort": 2342,
  "HttpServerMode": "",
  "HttpServerPassword": "",
  "SipsBin": "sips",
  "RawtherapeeBin": "rawtherapee-cli",
  "DarktableBin": "darktable-cli",
  "DarktablePresets": false,
  "HeifConvertBin": "heif-convert",
  "FFmpegBin": "ffmpeg",
  "ExifToolBin": "exiftool",
  "SidecarJson": false,
  "SidecarYaml": false,
  "SidecarPath": "",
  "PIDFilename": "",
  "LogFilename": "",
  "DetachServer": false,
  "DetectNSFW": false,
  "UploadNSFW": true,
  "GeoCodingApi": "places",
  "DownloadToken": "",
  "PreviewToken": "public",
  "ThumbFilter": "lanczos",
  "ThumbUncached": false,
  "ThumbSize": 2048,
  "ThumbSizeUncached": 7680,
  "JpegSize": 7680,
  "JpegQuality": 90
}

The originals path is not set now. And the assets path is still not set.

If I set

PHOTOPRISM_ASSETS_PATH = "/var/lib/photoprism/assets"
PHOTOPRISM_ORIGINALS_PATH = "/var/lib/photoprism/originals"
PHOTOPRISM_IMPORT_PATH = "/var/lib/photoprism/import"

And copy the installed assets folder to /var/lib/photoprism/assets

It works.

ghost commented 4 years ago

In summary, I do not think it is accurate to say

make all make install photoprism start

Is enough to run photoprism.

It is accurate to say a configuration file is not needed, but the _PATH environment variables are required to be set. And the error when they are not is not intuitive.

ghost commented 4 years ago

And here is a systemd service to run it.

[Unit]
After=network.target
Description=Photoprism

[Service]
Environment="HOME=/var/lib/photoprism"
Environment="PHOTOPRISM_ADMIN_PASSWORD=photoprism"
Environment="PHOTOPRISM_ASSETS_PATH=/var/lib/photoprism/assets"
Environment="PHOTOPRISM_DARKTABLE_PRESETS=false"
Environment="PHOTOPRISM_DATABASE_DRIVER=sqlite"
Environment="PHOTOPRISM_DEBUG=true"
Environment="PHOTOPRISM_DETECT_NSFW=false"
Environment="PHOTOPRISM_EXPERIMENTAL=false"
Environment="PHOTOPRISM_HTTP_HOST=127.0.0.1"
Environment="PHOTOPRISM_HTTP_PORT=2342"
Environment="PHOTOPRISM_IMPORT_PATH=/var/lib/photoprism/import"
Environment="PHOTOPRISM_JPEG_QUALITY=90"
Environment="PHOTOPRISM_JPEG_SIZE=7680"
Environment="PHOTOPRISM_ORIGINALS_PATH=/var/lib/photoprism/originals"
Environment="PHOTOPRISM_PUBLIC=false"
Environment="PHOTOPRISM_READONLY=false"
Environment="PHOTOPRISM_SETTINGS_HIDDEN=false"
Environment="PHOTOPRISM_SITE_AUTHOR="
Environment="PHOTOPRISM_SITE_CAPTION=Browse Your Life"
Environment="PHOTOPRISM_SITE_DESCRIPTION="
Environment="PHOTOPRISM_SITE_TITLE=PhotoPrism"
Environment="PHOTOPRISM_SITE_URL=http://localhost:2342/"
Environment="PHOTOPRISM_STORAGE_PATH=/var/lib/photoprism/storage"
Environment="PHOTOPRISM_THUMB_FILTER=lanczos"
Environment="PHOTOPRISM_THUMB_SIZE=2048"
Environment="PHOTOPRISM_THUMB_SIZE_UNCACHED=7680"
Environment="PHOTOPRISM_THUMB_UNCACHED=false"
Environment="PHOTOPRISM_UPLOAD_NSFW=true"

ExecStart=/usr/local/bin/photoprism start
ReadWritePaths=/var/lib/photoprism
Restart=always
RestartSec=10
StateDirectory=photoprism
User=photoprism
WorkingDirectory=/var/lib/photoprism

It is just a basic one, I will be hardening it up a lot but that might not work for everyone.

lastzero commented 4 years ago

Thanks for debugging this! Instead of marshalling the params struct you should be able to run photoprism config to see pretty much all config parameters and their values, see https://docs.photoprism.org/getting-started/config-options/

We've been focusing on the Docker version so far and will work on a real installer and standalone binaries as soon as possible. The instructions in the dev guide are specifically for our Docker image where the environment variables are set. Also I didn't have issues installing on OS X in the past. In general, you should at least provide the originals path and ideally also a storage path so that thumbs & index don't end up in the originals path.

lastzero commented 4 years ago

Should also your config to our docs when it's done 👍

ghost commented 4 years ago

No problem. I was more familiar with go than the photoprism command :D

If you want any help with systemd services, or a nix package/service in the future, give me a message.

lastzero commented 4 years ago

If a path is missing, photoprism now shows the following message:

# ./photoprism start
ERRO[2020-08-18T19:01:05+02:00] assets path not found, run 'photoprism config' to check configuration values 

Also reduced the log level for the settings file as many users thought this is an error and they need to take action.

lastzero commented 4 years ago

Master build is running: https://drone.photoprism.app/photoprism/photoprism/23

ghost commented 4 years ago

Hey, would you like me to test weather the message works?

I am not quite sure what acceptance test is.

lastzero commented 4 years ago

Just confirm if you're happy with the solution / charges :)

ghost commented 4 years ago

Yeah, I would say it would avoid the original issue from happening again.