approval icon indicating copy to clipboard operation
approval copied to clipboard

the approval flow is not triggered when adding the pendding tag Via the Files Automated Tagging App

Open eco-villenet opened this issue 4 years ago • 10 comments

the approval flow is not triggered when adding the pendding tag Via the Files Automated Tagging App. Files Automated Tagging App add the tag, the file is shown waiting for approval, but the file is not shared with the user enabled to approve. daniel-files approval-manual approval tag flow

eco-villenet avatar Sep 02 '21 02:09 eco-villenet

Thanks for the bug report.

It was quite tricky to fix that. I think it's fine now. Could you try latest nightly (v1.0.7-2-nightly) and confirm?

What's been done/fixed:

  • when a request is done via tag assignment (manual or automated tagging), make sure everything is done like a "UI" request
  • the requesting user is the file owner
  • adapt notifications and activities to those changes

julien-nc avatar Sep 02 '21 13:09 julien-nc

@eneiluj Thank you very much for your prompt attention to this bug. I have tested the changes, it has improved a bit. Now when assigning tag automatically, the flow seems to work well, file is shared, notes are added, and in UI everything looks good. On the side of the user who must approve, a notification is received, the file is seen, but it is corrupt. I leave image. auto auto1 version

The request by UI works without problems.

eco-villenet avatar Sep 02 '21 21:09 eco-villenet

I can't reproduce the problem. On the approver side, information is loaded successfully for the shared file in the sidebar. Do you see related errors in the browser console log? Or in nextcloud.log?

julien-nc avatar Sep 02 '21 21:09 julien-nc

I do not know what is happening, in the logs I do not see anything strange when uploading a file and triggering the auto tag. I only see that in the file detail there is already something strange ( You requested approval on test2-APPROVE.pdf.part) detail

Attached nextcloud log of a file upload process and automatic tag assignment and approval request. nextcloud.log request-approval.log

I only see the error in the nextcloud log when I try to see the detail from the approver side.

Will I have installed the version v1.0.7-2 wrong?

eco-villenet avatar Sep 03 '21 04:09 eco-villenet

Oh, in your case, it seems the intermediate files created when uploading are automatically tagged so they trigger an approval request... It does not happen to me, with small or big files.

How are you uploading the files? Via the web interface? Via the Desktop client?

Could you create a file (like a new text document) including APROBAR in its name and check if it works fine?

julien-nc avatar Sep 03 '21 10:09 julien-nc

yes, all the tests were uploading a file via web interface. Test by creating the document and assigning the name APROBAR at the time of creation. the result is the same. text

If I create the document with another name and then rename it, it works perfect. rename-file approver

I am going to create a new instance of nextcloud and install directly to version 1.0.7-2. I tell you the results.

eco-villenet avatar Sep 03 '21 14:09 eco-villenet

Thanks for your patience and precious feedback!

julien-nc avatar Sep 03 '21 14:09 julien-nc

sorry, try a fresh install of nextcloud, version 22.1.1 approval 1.0.7

Same result. new-nextcloud

eco-villenet avatar Sep 03 '21 16:09 eco-villenet

Hi, I've been doing more testing, not getting it to work. There is something that catches my attention, in the web UI, I can see that the name of the file is already corrupted (test2-APPROVE.pdf.part), but in the logs, there is no reference to that name, and that considering that I am in debug mode.

Another piece of information that I forgot to mention, in my configuration I am using the Oracle Bucket platform as storage. I don't know if that affects anything.

eco-villenet avatar Sep 03 '21 22:09 eco-villenet

Another piece of information that I forgot to mention, in my configuration I am using the Oracle Bucket platform as storage. I don't know if that affects anything.

Yeah it is most likely the reason why I can't reproduce the issue on my side. Could you setup a standard classic NC test instance?

If using an Oracle Bucket platform as storage is the cause of this remaining problem, then it has to be fixed on this side. There's not much I can do in the approval app which just handles the tag assignment event. This event should not be triggered for temporary partial files...

julien-nc avatar Sep 06 '21 15:09 julien-nc