Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deleted cards break "occ deck:export" #6446

Open
fracklaus opened this issue Oct 26, 2024 · 1 comment
Open

Deleted cards break "occ deck:export" #6446

fracklaus opened this issue Oct 26, 2024 · 1 comment

Comments

@fracklaus
Copy link

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Describe the bug

The occ deck:export functionality has a bug and does not work when a card has been deleted within deck. The following error appears:
[OCA\Deck\NoPermissionException]
Card is deleted

It seems that deck:export is checking for read access in /var/www/nextcloud/apps/deck/lib/Service/CommentService.php:46 by calling $this->permissionService->checkPermission(...). When executed on a deleted card, checkPermission throws an error "Card is deleted" that is not being catched.
The right reaction in deck:export should be to ignore the deleted card and continue with the next, instead of exiting due to the thrown exception.

To Reproduce
Steps to reproduce the behavior:

  1. Create a board in nextcloud deck as user USER
  2. Enter some cards
  3. Delete at least one card
  4. Execute occ deck:export USER
  5. Export will fail with "Card is deleted" exception

Expected behavior
A clear and concise description of what you expected to happen.

Export continues, deleted card is not part of export.

Screenshots
If applicable, add screenshots to help explain your problem.

Client details:

Error happens in command line on the server, client does not seem to be relevant.

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]
  • Device: [e.g. iPhone6, desktop]
Server details

Operating system: Debian 12

Web server: apache

Database: postgresql

PHP version: 8.2.24

Nextcloud version: (see Nextcloud admin page) 30.0.1.2

Where did you install Nextcloud from:

Signing status:

Login as admin user into your Nextcloud and access
http://example.com/index.php/settings/integrity/failed
paste the results here.

No errors have been found.

List of activated apps:

If you have access to your command line run e.g.:
sudo -u www-data php occ app:list
from within your Nextcloud installation folder

Nextcloud configuration:

If you have access to your command line run e.g.:
sudo -u www-data php occ config:list system
from within your Nextcloud installation folder

or

Insert your config.php content here
Make sure to remove all sensitive content such as passwords. (e.g. database password, passwordsalt, secret, smtp password, …)

Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/...

QctiveDirectory

Logs

Nextcloud log (data/nextcloud.log)

Insert your Nextcloud log here

Browser log

Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log
c) ...
@elzody
Copy link
Contributor

elzody commented Nov 4, 2024

I was able to reproduce this. The proper behavior upon first impression is to disregard any deleted cards and continue to the next.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants