[PSR-6][Errata] DateTimeInterface handling

42 views
Skip to first unread message

Larry Garfield

unread,
Jan 5, 2018, 11:37:21 AM1/5/18
to PHP Framework Interoperability Group
This has been on my back burner for a while, really too long. I was waiting
for the Secretary pool to refill, so here we are.

A ways back there was an errata vote for PSR-6 to address how to handle type
mismatches on expiresAt(), which is documented to \DateTimeInterface but not
type checked as such for PHP <5.5 compatibility. That vote was for using
trigger_error() to mimic a type check, which failed because lots of people
didn't like that approach.

Here's a new Errata addition that recommends using an exception instead, which
is more consistent with what existing libraries are already doing. This is
not a spec change, just recommended error handling of what should be an edge
case.

https://github.com/php-fig/fig-standards/pull/915

This is open for a 2 week discussion (ending 19 January), after which I'll
call a 2 week vote. I believe the vote should be just CC members, 2/3
majority, 50% quorum. (Secretaries, tell me otherwise if you disagree.) I
doubt there will be much to discuss/dispute here but there's no reason to not
go through the motions.

--Larry Garfield
signature.asc
Reply all
Reply to author
Forward
0 new messages