Conversation
6 tasks
davedrp
approved these changes
Nov 29, 2022
timparsons
approved these changes
Nov 29, 2022
Member
timparsons
left a comment
There was a problem hiding this comment.
Code looks great! Have some very minor suggested changes, but approving with the assumption they will be addressed
| PendingImportObject<BrAPIObservation> obsPIO = createObservationPIO(importRow, column.name(), column.getString(i)); | ||
| //If associated timestamp column, add | ||
| String dateTimeValue = null; | ||
| if (timeStampColByPheno.get(column.name())!=null) { |
Member
There was a problem hiding this comment.
from a code style standpoint, could you put spaces around !=. It will make the code more readable.
| if (timeStampColByPheno.get(column.name())!=null) { | ||
| dateTimeValue = timeStampColByPheno.get(column.name()).getString(i); | ||
| //If no timestamp, set to midnight | ||
| if (!validDateTimeValue(dateTimeValue) && !dateTimeValue.isBlank()){ |
Member
There was a problem hiding this comment.
Your logic here is sound. Minor suggestion, switch the order of the checks so that the isBlank check is first. This is easier to compute than validating the date/time, and can reduce the amount of work the system has to do when importing a file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Story: BI-1194 - Upload with timestamps
Changes to Experiment Import to enable import and preview display of timestamps associated with phenotypes.
Dependencies
bi-web/BI-1194
Testing
see bi-web
Checklist: