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

Allow spaces (and other things) as separators when parsing RFC3339 #700

Merged
merged 1 commit into from
Aug 27, 2024

Conversation

fasterthanlime
Copy link
Contributor

I don't like it anymore than you probably do, but the spec says so!

(and rusqlite uses that)

cf. https://hachyderm.io/@fasterthanlime/112834567377457088

@jhpratt
Copy link
Member

jhpratt commented Aug 1, 2024

I definitely don't like this, but I also don't like this from RFC2822.

It looks like tests are currently failing, as I explicitly tested for situations like this. The miri run will fail due to newer lints (it uses nightly unlike the rest of runs), so don't worry about that. With the tests updated, the change so far LGTM.

@jhpratt jhpratt added C-bug Category: bug in current code A-parsing Area: parsing A-well-known-format-description Area: well known format descriptions labels Aug 1, 2024
Copy link

codecov bot commented Aug 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.6%. Comparing base (4a74924) to head (d60fded).
Report is 43 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##            main    #700     +/-   ##
=======================================
- Coverage   97.8%   97.6%   -0.2%     
=======================================
  Files         81      83      +2     
  Lines       9378    9008    -370     
=======================================
- Hits        9169    8790    -379     
- Misses       209     218      +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@fasterthanlime
Copy link
Contributor Author

fasterthanlime commented Aug 1, 2024

It looks like codecov is unhappy because of two lines that it counts as being in the patch, but are not actually part of the lines I touched?

Edit: nope, codecov on mobile was not actually showing me the right lines. Fixing that now.

@fasterthanlime
Copy link
Contributor Author

Okay, the only failing tests is now miri, just like you said it would!

This is ready for review afaict, maybe a bit heavy on the comments — if you want to trim those a bit I don't mind! Feel free to adjust the PR before merging it (if the changes otherwise look good).

Note: I have not encountered any separators other than " " or "T" in the wild, so time could be stricter than RFC3339 but.. I'm not sure what the rationale would be! Your pick.

@fasterthanlime
Copy link
Contributor Author

@jhpratt Anything I can do to help this land?

@jhpratt
Copy link
Member

jhpratt commented Aug 7, 2024

@fasterthanlime Probably the only thing would be rebasing to get miri passing. That'll save me the ~30 seconds to do it myself. Aside from that, I've been extremely busy. I do intend on reviewing this quite soon though!

@fasterthanlime
Copy link
Contributor Author

Just rebased as requested! 30 seconds is 30 seconds 😎

@jhpratt
Copy link
Member

jhpratt commented Aug 27, 2024

Thanks again! Sorry about the delay.

@jhpratt jhpratt merged commit f22bced into time-rs:main Aug 27, 2024
22 checks passed
tyranron added a commit to graphql-rust/juniper that referenced this pull request Dec 3, 2024
tyranron added a commit to graphql-rust/juniper that referenced this pull request Dec 3, 2024
tyranron added a commit to graphql-rust/juniper that referenced this pull request Dec 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-parsing Area: parsing A-well-known-format-description Area: well known format descriptions C-bug Category: bug in current code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants