Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sealog/Seaplay Navigation Time Displayed is always YYYY.0 (i.e. 2023.0) #64

Open
cgraver opened this issue Aug 6, 2023 · 2 comments
Open
Assignees

Comments

@cgraver
Copy link

cgraver commented Aug 6, 2023

On Alvin Sealog and Seaplay, and on seaplay.whoi.edu for Jason and Alvin, "Time" within the Navigation box always displays "YYYY.0" with YYYY being the year of the cruise. This has persisted across all cruises I've gone through, back to 2020 at least.

@cgraver
Copy link
Author

cgraver commented Aug 6, 2023

NavTime

@rgov
Copy link
Member

rgov commented Aug 6, 2023

Related to #61. The time field is stored like 2023-07-10T15:23:27.105Z. The solution in #62 was to run parseFloat() on the input and check if it is NaN. But, since the time field begins with a valid float (2023), this check doesn't work.

I think we should move to a different technique than using parseFloat(), such as a regular expression, /^[+-]?(?:\d*\.\d+|\d+\.\d*)$/. This only detects numbers with a decimal point (and excludes scientific notation).

(The root cause of this is that Sealog doesn't use typed data and everything is stored as a string.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants