Skip to content

X-79 Fix dones CSV Import#252

Merged
HerbCaudill merged 2 commits intomainfrom
x-79-fix-dones-import
Feb 21, 2025
Merged

X-79 Fix dones CSV Import#252
HerbCaudill merged 2 commits intomainfrom
x-79-fix-dones-import

Conversation

@jskunkle
Copy link
Contributor

@jskunkle jskunkle commented Feb 4, 2025

As described in X-79 or issue #237 - the bulk csv dones import wasn't working. Here's a quick rundown of the changes in this pr:

DoneEntryImporter.tsx

  • Line 17 - the missing return statement was the real fix here
  • Line 51-56 - correcting the watermark instructions of the import textbox and giving more complete examples

csvToDoneEntries.ts

  • Line 13 & 42 - removing the old timestamp field, I'm honestly not even sure what this field represented (the date the done was created?) but herb and I agreed this could be removed
  • Line 29 - allows the user to enter an empty space/nothing instead of an empty array for likes

csvToDoneEntries.test.ts

csvToDoneEntries doesn't require clients or projects as there's no way to tag dones to either

The real fix here is the return on line 17 but I also updated the instructions in the import textbox watermark as the listed format was incorrect
@linear
Copy link

linear bot commented Feb 4, 2025

X-79 fix dones csv import

from this comment on #231 :

I've been playing with this branch for some time and everything seems to be working a-ok except for the CSV import dones data tools under danger zone. Its almost as if the dones csv schema or import code accidentally crossed up with the hours csv import but I didn't poke too hard at this in case it's out of the scope of this PR, this field has been abandoned, this is a known bug or something else. Let me know if you want me to dig more into this, open up a github issue or something else.

Here's what I'm running into: First it took me so time to figure out the csv format that makes the validation happy. The format in the text box watermark (Name, Date, Comment) doesn't work - you get the following error

image

Second - I eventually figured out that the dones csv import wants 6 fields (not 100% sure yet what each field is). However even when I enter CSV that makes the validator happy the "Replace ALL dones with imported data" button is never enabled (even tho there's no error)

image

Finally - when messing with the input CSV manually, the validation is kludgy. It's often "one step behind" and errors don't ever clear once you get a validation error. For example, I received a validation error and then edited the csv line a number of times to get to something that (should) make the validation happy...however you can see that the error is incorrect and I can't get the validation error to go away or the "Replace ALL dones with imported data" button to enable.

image

Again - let me know if I can dig deeper, provide more info or if I'm just barking up the wrong tree. Outside of the import dones CSV everything seems to be working correctly. Thanks

@pull-request-size pull-request-size bot added size/M and removed size/S labels Feb 20, 2025
@HerbCaudill HerbCaudill merged commit 1c67c1d into main Feb 21, 2025
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants