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

Let core:archive continue even if the website was deleted in the meantime #14393

Closed
paladox opened this issue May 1, 2019 · 6 comments · Fixed by #14403
Closed

Let core:archive continue even if the website was deleted in the meantime #14393

paladox opened this issue May 1, 2019 · 6 comments · Fixed by #14403
Labels
Bug For errors / faults / flaws / inconsistencies etc.

Comments

@paladox
Copy link
Contributor

paladox commented May 1, 2019

Hi, could a option be added that allows you to continue even if you get a error like:

[Piwik\Exception\UnexpectedWebsiteFoundException]
An unexpected website was found in the request: website id was set to '2897' .

please?

This would be super useful.

Or is there a way to clear the deleted websites so they are not run?

@tsteur tsteur added the Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. label May 1, 2019
@tsteur tsteur added this to the Backlog (Help wanted) milestone May 1, 2019
@tsteur
Copy link
Member

tsteur commented May 1, 2019

We would not add an option but we could in general implement this as standard behaviour. I'm seeing for some things this is already implemented in the archiver, eg when archiving days, but not in some other places.

@paladox
Copy link
Contributor Author

paladox commented May 1, 2019

@tsteur would you know how I would be able to fix this? Is there another command i should run to fix this please? :)

@tsteur
Copy link
Member

tsteur commented May 1, 2019

@paladox I suppose this file here https://github.com/matomo-org/matomo/blob/3.10.0-b1/core/CronArchive.php would need to be patched in some places to catch UnexpectedWebsiteFoundException similar to here: https://github.com/matomo-org/matomo/blob/3.10.0-b1/core/CronArchive.php

There isn't any workaround I'm aware of.

@paladox
Copy link
Contributor Author

paladox commented May 1, 2019

https://github.com/matomo-org/matomo/blob/3.10.0-b1/core/CronArchive.php is the same as your first link :)

@tsteur
Copy link
Member

tsteur commented May 1, 2019

Sorry, looks like I need some coffee haha :) here is the correct link: https://github.com/matomo-org/matomo/blob/3.10.0-b1/core/CronArchive.php#L696-L699

paladox added a commit to paladox/matomo that referenced this issue May 1, 2019
This is to allow the archive to continue if the site was deleted from matomo.

Fixes matomo-org#14393
@paladox
Copy link
Contributor Author

paladox commented May 1, 2019

@tsteur thanks for the pointer! Fixed in #14397 !

paladox added a commit to paladox/matomo that referenced this issue May 2, 2019
This is to allow the archive to continue if the site was deleted from matomo.

Fixes matomo-org#14393
tsteur pushed a commit that referenced this issue May 2, 2019
* CronArchive: Catch UnexpectedWebsiteFoundException

This is to allow the archive to continue if the site was deleted from matomo.

Fixes #14393

* Update CronArchive.php
@mattab mattab changed the title Add option to core:archive that allows you to continue even if the site is not in matomo anymore Let core:archive continue even if the website was deleted in the meantime Jun 29, 2019
@mattab mattab added Bug For errors / faults / flaws / inconsistencies etc. and removed Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. labels Jun 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc.
Projects
None yet
3 participants