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

Possible fix for #356 #357

Closed
wants to merge 1 commit into from
Closed

Conversation

cisaacstern
Copy link
Contributor

closes #356

This works, but there may be a better way to do this, thus "possible" in the title.

And specifically, perhaps @atmorling has some insight into any relationship between #356 and the fix for #352 (which may point to a better solution).

@atmorling
Copy link
Contributor

atmorling commented Dec 11, 2024

I think something like this makes sense:

events_df["time"] = events_df["geojson"].apply(lambda x: ptime(x.get("properties").get("datetime"))
events_df = clean_time_cols(events_df)

Basically tease out the time data from the geojson before we do clean_time_cols
Then we shouldn't need any extra formatting in this function.

@cisaacstern
Copy link
Contributor Author

Oh cool, yeah if that works that sounds better! I figured you'd have a good insight on this.

@cisaacstern
Copy link
Contributor Author

If you'd like me to make a stab at that I can try, though tbh if you're keen, I think you're in a better place in re: familiarity with this section of code. So I'd be happy to just close this PR and have it superseded by your proposed fix.

@atmorling
Copy link
Contributor

Sure, will do!

@atmorling
Copy link
Contributor

Superseded by #358

@atmorling atmorling closed this Dec 11, 2024
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

Successfully merging this pull request may close these issues.

In EarthRangerIO.get_patrol_events, geojson datetime format is not always "%Y-%m-%dT%H:%M:%S%z"
2 participants