Open lluisgener opened 2 years ago
I managed to get it to work for me, but there are still issues. Search isn't working and reload isn't either. I can send you my files if you want, as I can not remember what all I changed anymore.
If you can, I would appreciate it.
Thanks.
Our debt is growing but we will try
pls append your changed or you can open PR with changes
I tried making a PR, but it doesn't notice my changes but tells me that everything is different. Here are my files, as I said it is working for me, but not perfect.
Just as info, the new loader seems to require a specific structure and also specific "classes" within this structure. I just added a empty variable in that case to get rid of the error but I guess to make it rubust you would have to redo how the plugin is setup.
I also played a while...but it didn't work...would be great if it runs on Redmine 5!
I made the attached vault.zip by @JanB97 work by adding this to the gemfile:
if Gem::Version.new(redmine_version_major) >= Gem::Version.new('4') gem 'protected_attributes_continued', '1.8.2' end
and replacing line 112 in keys_controller.rb for:
if @key.update(params[:vault_key])
It seems to read the previous keys, and I've been able to add, update and delete new ones. I don't know if I need to test much more.
I made the attached vault.zip by @JanB97 work by adding this to the gemfile:
if Gem::Version.new(redmine_version_major) >= Gem::Version.new('4') gem 'protected_attributes_continued', '1.8.2' end
and replacing line 112 in keys_controller.rb for:
if @key.update(params[:vault_key])
It seems to read the previous keys, and I've been able to add, update and delete new ones. I don't know if I need to test much more.
Oh cool, works with the gem! However, I fear that the gem will eventually stop working - but it's a great workaround, at least for now Thanks :)
Ok so I have tried the change by @JanB97 and the updates by @lluisgener as well but I keep getting this:
Zeitwerk::NameError: expected file /opt/redmine/plugins/vault/lib/mk_keyfiles_dir.rb to define constant MkKeyfilesDir, but didn't
/var/lib/gems/2.7.0/gems/zeitwerk-2.6.4/lib/zeitwerk/loader/callbacks.rb:25:in `on_file_autoloaded'
/var/lib/gems/2.7.0/gems/zeitwerk-2.6.4/lib/zeitwerk/kernel.rb:42:in `require'
Ignore, I was trying to use the repository and not the zip provided by @JanB97 .
Thank you guys for your help. I will try and see if I can commit this through my repository and get back to you with a merge request.
Hello.
Is it possible to make the plugin compatible with new redmine 5?
There seems to be a compatibility issue with the new Zeitwerk loader.
Thanks in advance.