Commit graph

102 commits

Author SHA1 Message Date
Shish
db0e788a67 [core] Deduplicate ImageAdditionEvent & ImageInfoSetEvent
Rather than ImageAddition triggering TagsSet/SourceSet/LockSet etc in one way, and ImageInfoSet triggering TagsSet/SourceSet/LockSet in a different way, why not have ImageAddition *just* deal with image addition, and then send a separate ImageInfoSet to deal with all of the metadata setting?
2024-02-20 22:15:24 +00:00
Shish
e80d235fe9 [core] use Safe library, reduce StdLibEx 2024-02-20 10:38:20 +00:00
Shish
7ee4152942 [core] organise exceptions a bit 2024-02-11 16:03:23 +00:00
Shish
8c22cb1fb6 [core] exact and named page args 2024-02-11 11:34:17 +00:00
Shish
6d1bf8eede [admin] have AdminActionEvent carry its own params 2024-02-10 00:00:49 +00:00
Shish
82a3ce25c2 level 7 typing 2024-01-20 23:27:34 +00:00
Shish
b60c3fe362 [core] a load more type hints, and fix bugs revealed by type hints 2024-01-20 14:11:00 +00:00
Shish
bb9ab613ce [everything] bulk set event handler return types to void 2024-01-15 11:52:35 +00:00
Shish
7b9201cb42 [core] Database::with_savepoint() 2024-01-09 21:59:24 +00:00
Shish
4d011fa5e5 [core] remove add_image, send_event(DataUpload) is much clearer as to what it's actually doing 2024-01-09 19:24:56 +00:00
Shish
4b954b2e68 [cron_uploader] don't try to upload .listing files, see #972 2024-01-05 15:31:21 +00:00
Shish
af309601f5 [upload] separate out DataUpload, ImageAddition, and TagSet/SourceSet/LockSet/etc 2024-01-05 15:00:07 +00:00
Shish
e3febc5488 [cron_uploader] minor fixes 2024-01-04 19:21:29 +00:00
Shish
ff04083ad5 [handle_archive] merge tags from inside the archive and the form, fixes #483 2024-01-04 15:55:48 +00:00
Shish
fd1bb21f9d bumps 2023-11-11 22:05:28 +00:00
Shish
00d4f9f75c always have a Themelet, never null 2023-06-27 16:11:14 +01:00
Shish
c5e2353447 manual timeouts 2023-06-25 14:19:52 +01:00
Shish
b85e7ec209 manually control timeout, to dump trace data after hitting the limit 2023-06-25 13:40:57 +01:00
Shish
36951db563 use DataUploadEvent fields rather than required metadata 2023-02-24 22:42:03 +00:00
Shish
689b2b13af send_event(T) -> T 2023-02-04 20:50:26 +00:00
Shish
1f48c5ba19 remove some unused bits 2023-01-11 18:28:43 +00:00
Shish
2a18322dd5 god damn it php 2023-01-11 13:27:57 +00:00
Shish
0d77a1dc81 nits 2023-01-11 11:46:42 +00:00
Shish
bce2d55744 Namespaces are one honking great idea—let's do more of those! 2023-01-10 22:44:09 +00:00
Shish
0be8e835ef avoid crashing in cron_upload if API key isn't set, fixes #881 2022-10-27 17:15:48 +01:00
Shish
3d9e32e919 new php-cs-fixer 2021-12-14 18:32:47 +00:00
Shish
77f7121e26 drop php7.3 support, make use of 7.4 features 2021-03-14 23:43:50 +00:00
Matthew Barbour
32927aea3d Formatting pass 2021-01-18 08:37:32 -06:00
Matthew Barbour
fe7b93d6d3 Added max time remaining debug logging to cron upload 2021-01-16 14:35:59 -06:00
Matthew Barbour
6282881c4a Changed cron uploader to better handle concurrent run attmpts 2021-01-16 14:35:54 -06:00
Matthew Barbour
e7d11f2310 Converted cron_upload to be able to run per-user, using user API keys 2021-01-16 14:35:04 -06:00
Matthew Barbour
72268d529d Moved user options to separate page, modularized the settings page code so that it can be re-used to simplify and standardize user settings in the same manner as global settings 2021-01-16 14:26:17 -06:00
Matthew Barbour
ba982e4451 Image to Post - cron upload 2020-10-26 10:53:28 -05:00
Matthew Barbour
45d38d8833 Added more specific upload error message that includes detected mimetype 2020-10-26 07:27:16 -05:00
Matthew Barbour
984c9702ec The great MIMEing 2020-06-25 00:42:34 +01:00
Matthew Barbour
30f62c2ff8 Fixed transaction issue between cron uploader and bulk import 2020-06-23 15:11:35 +01:00
Matthew Barbour
9b9f1d0341 Cleaned up some warnings in bulk import/export extension
Added transactions to bulk import
Renamed beginTransaction to begin_transaction for naming consistency
Updated cron uploader to handle bulk import transactions
2020-06-23 15:07:00 +01:00
Matthew Barbour
f6923af8ab Added source logging to cron upload output when all sources are enabled 2020-06-22 18:03:03 +01:00
Matthew Barbour
86f7a06ed0 New options for cron uploader:
Logging level
Including all logs in output
Stop on error instead of continuing
2020-06-03 20:00:54 +01:00
Matthew Barbour
e1aefb78ab Fix for cron uploader issue with root paths ending in a slash 2020-06-03 19:59:29 +01:00
Matthew Barbour
12c331cbd2 Removed extra tag set from cron uploader, no longer needed now that it runs as a user 2020-06-03 19:58:57 +01:00
Matthew Barbour
007e07e507 Various changes to cron uploader:
Removed count limit, the cron job now checks the max PH execution time and auto-stops itself at 80% of that value.

Now skips os-specific image cache files like thumbs.db and the __macosx folder.

Changed failed folder re-deployment to allow re-deploying to populated queue, making it easier to re-process lots of failed batches all at once.

Changed page to output as a stream, allowing a long-running process to provide output as it runs rather than just at the very end.

Changed import loop to use the yield convention, allowing faster consumption of found files and lower memory use overall.
2020-06-03 19:57:27 +01:00
Shish
e46b319295 set theme classes 2020-02-04 00:46:36 +00:00
Shish
9eb5acf2dc use strict types 2020-01-26 16:27:56 +00:00
Shish
70db0ce5bd flash_message -> page->flash, with no cookies 2019-12-15 19:47:18 +00:00
Shish
247cfcbd77 Avoid shadowing global variable
When we aren't referencing the current `global $user`, we should give it
a different name to avoid confusion
2019-11-11 16:43:42 +00:00
Shish
d17e207984 Have get_arg never return null
90% of places assume it will never return null, and they will break in
weird ways if it does return null
2019-11-04 00:40:10 +00:00
Shish
55c6854003 formatting 2019-11-02 19:57:34 +00:00
Matthew Barbour
d605e0e572 Added cron_admin permission 2019-10-17 14:26:14 -05:00
matthew
40269a6f4a Cron uploader enhancements and bug fixes 2019-10-10 10:16:15 -05:00