biocore / biocore/microsetta-admin

Blank Spreadsheet Rows on Daklapack Bulk Order

Open
#100 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
0
Forks
10
PR merge metrics
No merged PRs in 30d

Description

I just observed an issue where blank rows in a spreadsheet used to place a bulk order with Daklapack were treated as data and our system attempted to place empty orders through Daklapack's API. When I open the XLS file, I see two rows - the header, and a single address. However, when I convert the XLS file to CSV, it renders as follows (with most of the actual values redacted):

```
firstName,lastName,address1,insertion,address2,postalCode,city,state,country,countryCode
[REDACTED FIRST NAME],[REDACTED LAST NAME],[REDACTED ADDRESS1],,[REDACTED ADDRESS 2],[REDACTED ZIP],[REDACTED CITY],CA,USA,us
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
,,,,,,,,,
```

When our system processed the file for ordering, it returned one success message for the row with actual values, then 11 validation errors from the Daklapack API for the empty rows.

While this is largely an issue with Excel functioning counterintuitively, it would be good to enforce very basic validation before attempting to place a bulk order with Daklapack, such as making sure all required fields are present. If a row is entirely empty, silently discarding the row would be fine. Otherwise, warning the user without attempting to contact Daklapack's API for that row would be appropriate.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the Daklapack bulk-order CSV ingestion and ordering entry point, then reproduce the issue with a CSV containing trailing empty rows. Check how required fields are validated before API requests. Done means empty rows are discarded and partially populated rows produce warnings without contacting Daklapack.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.