feat(jobs): Implement garbage collection job #506

Merged
inex merged 6 commits from naiji/garbage-collection into master 2024-05-25 12:32:21 +03:00
Collaborator
There is no content yet.
NaiJi added the
Feature request
Priority
Low
Severity
Low
Source
Core Team
labels 2024-05-19 06:29:31 +03:00
NaiJi self-assigned this 2024-05-19 06:29:31 +03:00
NaiJi added 1 commit 2024-05-19 06:29:32 +03:00
NaiJi requested review from inex 2024-05-19 06:29:36 +03:00
misterfourtytwo reviewed 2024-05-20 21:04:51 +03:00
@ -93,6 +93,11 @@ class JobsContent extends StatelessWidget {
);
},
),
const SizedBox(height: 10),

use Gap please

use `Gap` please
Poster
Collaborator

wow we have that now?! letsgooooo

wow we have that now?! letsgooooo
misterfourtytwo reviewed 2024-05-20 21:05:30 +03:00
@ -95,1 +95,4 @@
),
const SizedBox(height: 10),
BrandButton.text(
onPressed: () => context.read<JobsCubit>().collectNixGarbage(),

onPressed: context.read<JobsCubit>().collectNixGarbage

`onPressed: context.read<JobsCubit>().collectNixGarbage`

It is better to place this button in the storage management screen, not on the Jobs screen. We don't want big emphasis on this feature.

It is better to place this button in the storage management screen, not on the Jobs screen. We don't want big emphasis on this feature.
NaiJi added 1 commit 2024-05-21 03:22:04 +03:00
NaiJi added 1 commit 2024-05-21 03:26:05 +03:00
inex requested changes 2024-05-22 12:20:10 +03:00
@ -65,0 +74,4 @@
!jobs.any((final job) => job is CollectNixGarbageJob);
@override
Future<(bool, String)> execute() async => (false, 'unimplemented');

This is kinda a bad approach, as you're reusing code intended to be refactored out in the new code.

It would be better to make it a one-shot request to the API, and then our existing server-side jobs code will track it without any changes to it.

This is kinda a bad approach, as you're reusing code intended to be refactored out in the new code. It would be better to make it a one-shot request to the API, and then our existing server-side jobs code will track it without any changes to it.
NaiJi added 2 commits 2024-05-23 05:15:34 +03:00
NaiJi requested review from inex 2024-05-23 05:15:48 +03:00
inex added 1 commit 2024-05-25 12:31:26 +03:00
inex approved these changes 2024-05-25 12:32:02 +03:00
inex merged commit 291a6507ae into master 2024-05-25 12:32:21 +03:00
inex deleted branch naiji/garbage-collection 2024-05-25 12:32:21 +03:00
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: SelfPrivacy/selfprivacy.org.app#506
There is no content yet.