The original function name was named poorly however.
397 karma · joined November 5, 2014
The original function name was named poorly however.
For example, the bypass valve on the boiler must be opened in 30 hours. You want that as UTC instead of wall time as you don't want a DST change to add an extra hour to that as you'd get a pile of scrap instead of an intact boiler.
I think I see the confusion here. If you went to a group of people and said the movie you were all going to was rescheduled from 11pm UTC to 10pm UTC because of DST you'd get a bunch of "Huh?" and "What local time was it rescheduled to?" You'd answer it was rescheduled from 6pm to 6pm local time. You'd get a bunch of laughs at your "geek humour" while they secretly thought you were nuts. :)
Social events like meetings, movies, etc. are not considered rescheduled when DST starts/stops or the TZ rules get changed.
If you stored the event as UTC you'd have to alter your database when DST starts/stops or the TZ rules changed (is your system going to compare the old and new rules automatically now?).
UTC is the correct was to store timestamps (things that happened) and intervals (things that need to happen x seconds/minutes/hours from now).
For future events at a specific geographical location you need to store it as local time + timezone. Many databases have a time+timezone type.
YOU just rescheduled the event.
Works the same with dates and not just times. If you store each of those events individually and the politicians move the DST switch date (or an error was corrected in the TZ database) then some of your event times will now be an hour off.
Intervals should be stored in UTC. If you're supposed to drop the control rods in a reactor in 24 hours you store the time it's supposed to happen in UTC. DST transitions and rule changes would mess this up if stored in local time.
Timestamps for logs and files should also always be UTC.
Basically he says that the Saudis don't trust OPEC, are pro production cuts but won't cut their own production because they got burned in the past.
I stopped reading right there.
Didn't know that. It will simplify my http to https redirect configuration.
Do you know where the redirect and ignoring expiry dates is documented?
So I'll be sticking with 2.7 for now.
None of this is true for the resource fork in the Mac case.
And this perfectly illustrates what I posted in another comment elsewhere. Thinking that doing operations on code points (indexing and length) is the proper thing to do. You need to use a unicode library to work on graphemes and take into account grapheme clusters.
> For regexes, \w matches any unicode word character
From what I've read, \w just matches code points. I did find that the https://pypi.python.org/pypi/regex module supports \X which matches graphemes as per the unicode spec http://www.unicode.org/reports/tr29/.
No, they make a clear distinction between bytes and code points. This is the wrong approach as code points are not characters. People are going to think that everything is fine now that they're using code points and the unicode type when they should be using a unicode library for text manipulation.
I've always wanted to know how things are done internally. Makes me a better programmer. What I said about all this extra conversion does to performance is correct, especially when scaling up.
And my choice to use UTF-8 internally is a valid way to do things. I make sure that what comes in from the outside world is UTF-8 (either by rejecting or converting) and then don't have to worry about it from that point on. The bulk of my code deals with outbound data so no need for me to do any encoding as it's already UTF-8.
As for regular expressions, they work perfectly if your delimiters are in the ASCII range. If you're trying to match a single character then they don't work for Unicode even when using Python3's unicode type. The reason is that code points are not characters.
And I don't want to be forced to distinguish between strings and bytes. To me they are one and the same as I use UTF-8 for everything. Not once in my code do I need to encode/decode anything.
It's non-BMP characters that trigger the conversion to 4 bytes per codepoint. Unfortunately Emoji are non-BMP and are super common.
Turns out the CPU aux power connector was not hooked up. I must have knocked it loose while working on the innards a while back. The machine has been rock solid ever since I reconnected it.
Renewal and revalidation are not the same process. Unfortunately they're thinking about making the revalidation period 90 days as well. That would suck as I have several sites where the content is generated by a script which would have to be disabled to serve a file.
Python 3 already required all code to be looked over because of the string literal change so it wouldn't be much different.
I wish Python went with UTF-8 instead of their multi width internal representation.