liberu-genealogy / genealogy-laravel

Full genealogy application using Laravel 11, PHP 8.3, Filament 3.2 and Livewire 3.5
https://www.liberu.net
MIT License
113 stars 59 forks source link

Sweep: fix dna upload #86

Closed curtisdelicata closed 5 months ago

curtisdelicata commented 5 months ago

Details

Rename job dispatch from ImportDna to DnaMatching. Make sure that DnaMatching laravel job is correctly dispatched and the function is called by the file upload in the file app/Filament/Resources/DnaResource.php

Checklist - [X] Modify `app/Filament/Resources/DnaResource.php` βœ“ https://github.com/liberu-genealogy/genealogy-laravel/commit/93ec504c69fa01236347f838571fe2f9b5d3614d [Edit](https://github.com/liberu-genealogy/genealogy-laravel/edit/sweep/fix_dna_upload/app/Filament/Resources/DnaResource.php#L25-L25) - [X] Running GitHub Actions for `app/Filament/Resources/DnaResource.php` βœ“ [Edit](https://github.com/liberu-genealogy/genealogy-laravel/edit/sweep/fix_dna_upload/app/Filament/Resources/DnaResource.php#L25-L25)
sweep-ai[bot] commented 5 months ago

πŸš€ Here's the PR! #89

See Sweep's progress at the progress dashboard!
⚑ Sweep Basic Tier: I'm using GPT-4. You have 5 GPT-4 tickets left for the month and 3 for the day. (tracking ID: eb86073525)

For more GPT-4 tickets, visit our payment portal. For a one week free trial, try Sweep Pro (unlimited GPT-4 tickets).

[!TIP] I'll email you at genealogysoftwareuk@gmail.com when I complete this pull request!


Actions (click)

GitHub Actionsβœ“

Here are the GitHub Actions logs prior to making any changes:

Sandbox logs for e91fd9e
Checking app/Filament/Resources/DnaResource.php for syntax errors... βœ… app/Filament/Resources/DnaResource.php has no syntax errors! 1/1 βœ“
Checking app/Filament/Resources/DnaResource.php for syntax errors...
βœ… app/Filament/Resources/DnaResource.php has no syntax errors!

Sandbox passed on the latest main, so sandbox checks will be enabled for this issue.


Step 1: πŸ”Ž Searching

I found the following snippets in your repository. I will now analyze these snippets and come up with a plan.

Some code snippets I think are relevant in decreasing order of relevance (click to expand). If some file is missing from here, you can mention the path in the ticket description. https://github.com/liberu-genealogy/genealogy-laravel/blob/e91fd9ec1b3aac84d075239e7810fa474bac516e/app/Filament/Resources/DnaResource.php#L20-L28

Step 2: ⌨️ Coding

--- 
+++ 
@@ -22,7 +22,7 @@
     {
         return $form->schema([
             Forms\Components\TextInput::make('name')->required()->maxLength(255),
-            FileUpload::make('attachment')->required()->maxSize(100000)->directory('dna-form-imports')->visibility('private')->afterStateUpdated(ImportDna::dispatch($request->user(), $manager->storagePath($path), $state)),
+            FileUpload::make('attachment')->required()->maxSize(100000)->directory('dna-form-imports')->visibility('private')->afterStateUpdated(DnaMatching::dispatch($request->user(), $manager->storagePath($path), $state)),
         ]);
     }

Ran GitHub Actions for 93ec504c69fa01236347f838571fe2f9b5d3614d:


Step 3: πŸ” Code Review

I have finished reviewing the code for completeness. I did not find errors for sweep/fix_dna_upload.


πŸŽ‰ Latest improvements to Sweep:
  • New dashboard launched for real-time tracking of Sweep issues, covering all stages from search to coding.
  • Integration of OpenAI's latest Assistant API for more efficient and reliable code planning and editing, improving speed by 3x.
  • Use the GitHub issues extension for creating Sweep issues directly from your editor.

πŸ’‘ To recreate the pull request edit the issue title or description. To tweak the pull request, leave a comment on the pull request.Something wrong? Let us know.

This is an automated message generated by Sweep AI.