484 Matching Annotations
  1. Dec 2023
  2. Nov 2023
    1. Authentication establishes who someone is, and is commonly referred to as user sign-up or sign-in. Authorization is the process of granting or rejecting access to data or resources.
    2. The signed-in status of a Google Account, and your app's session state and signed-in status are distinct, separate concepts. User sign-in status to their Google Account and your app are independent of each other
    1. Please contact Google for support on Gmail. This really isn't an action that has anything to do with your Mac. You can access all of your mail online in a web browser. What you would like to do isn't an action of the Mail app which is simply a client but would be managed by the ISP, in your case Google.
  3. Oct 2023
    1. "Usage is trendy, arbitrary, and above all, constantly changing, like all other fashions--in clothing, music, or automobiles. Grammar is the rationale of a language; usage is the etiquette."​ 
    2. In this book, grammar refers to the manner in which the language functions, the ways that the blocks of speech and writing are put together. Usage refers to using specific words in a manner that will be thought of as either acceptable or unacceptable. The question of whether or not to split an infinitive is a consideration of grammar; the question of whether one should use literally in a nonliteral sense is one of usage."
    1. The term "Hobson's choice" is often used to mean an illusion of choice, but it is not a choice between two equivalent options, which is a Morton's fork, nor is it a choice between two undesirable options, which is a dilemma. Hobson's choice is one between something or nothing.
    2. A Hobson's choice is different from:
    1. transitive verb

      It's hard for me to see the difference between the transitive and intransitive forms of this verb.

      Is that the transitive form can/must be used with a noun following it, like "presume something", while the intransitive form cannot be followed by a noun, but can (and often is) followed by a prepositional phrase, "presume that something"? Pretty subtle difference, but I guess it's there...

  4. Sep 2023
    1. Exclude and include rules are resolved relative to the root of the transfer, but finding rule files (e.g. --exclude-from='exclude-list') is done relative to the working directory of the rsync process (which it inherits from the process that ran it).
    1. There is actually no meaningful distinction between a hostname which happens to be a second-level domain and a hostname which has more parts than that. You can even have a machine at a top-level domain if you happen to be a small country or otherwise are able to create an A record for one.
    1. The host itself does not handle the actual FQDN. That is handled by the DNS. FQDN (Fully Qualified Domain Name) is handled by DNS translating names into IP addresses. Using the /etc/hosts file, you are essentially overriding the DNS server.
    1. Each message you send out has both the sender and from address. Simply put, the sender domain is what the receiving email server sees when initiating the session, and the from address is what your recipients will see.
    1. This nuance is important as the Sender field is an envelope field and the From is an email header field - each representing different aspects of the message. 
    1. Note that used_refinements is a class method of a Module, and put there just for organizational purposes, while returning refinements list of the current context. There is no way to ask arbitrary module which refinements it uses (e.g., there is no Calculator.used_refiments).
  5. Jul 2023
    1. The distinction doesn't refer to the files _contents_ but how to the file is _treated_ when it is being read or written. In "rb"/"wb" modes files are left how they are, in "r"/"w" modes Windows programmers get line ends "\r\n" translated into "\n" what disturbs file positions and string lengths.
  6. Jun 2023
    1. It actually depends on if your class is a data class or a behaviour class.

      first time I've come across this idea of data class vs. behavior class

    2. to clarify, I am distinguishing between properties as representing state and methods representing actions
    1. Effective permissions are the roles and data restrictions that a member is assigned via other resources (like the organization, a user group, or an account that includes the current property) plus all the direct permissions assigned explicitly for the current resource. Direct permissions are role and data restrictions that a member is assigned explicitly for the current resource (e.g., organization, account, property).
  7. May 2023
    1. Some say you should treat addresses as case-preserving as opposed to case-sensitive, meaning you don't change IStillUse@AOL.COM to istilluse@aol.com but you still consider it a dupe of iSTilLUSE@aol.com.
  8. Apr 2023
    1. If the target resource does not have a current representation and the PUT successfully creates one, then the origin server MUST inform the user agent by sending a 201 (Created) response. If the target resource does have a current representation and that representation is successfully modified in accordance with the state of the enclosed representation, then the origin server MUST send either a 200 (OK) or a 204 (No Content) response to indicate successful completion of the request.
  9. Mar 2023
    1. Missing field can be a field that has not been sent and that's clearly a 400 to me, because the app cannot understand this payload, it violates the contract. IMHO, 400 suits better to not well-formed JSON, JSON that has different key names (contract violation) and JSON that one or more of the field(s) contents is from another type, let's say, you expect a int and got an object. Even not null constraint can be in both status codes, 400 if field not sent at all (and most frameworks understands it as null), and 422 if sent but with null value.
    1. You can also find the combination verb+in+to, but in that case you're usually dealing with a phrasal verb consisting of a verb and the particle "in", which happens to be followed by the preposition "to".They wouldn't give in to our demands.
    2. "Built in to" appears when you use the phrasal verb "build in" followed by an infinitive, but that is not what you are trying to do in your sentence.There's an electronic switch built in to stop all data transfers.
    1. When I speak of Europeans or mental Europeans, I'm not allowing for false distinctions. I'm not saying that on the one hand there are the by-products of a few thousand years of genocidal, reactionary, European intellectual development which is bad; and on the other hand there is some new revolutionary intellectual development which is good. I'm referring here to the so-called theories of Marxism and anarchism and "leftism" in general. I don't believe these theories can be separated from the rest of the of the European intellectual tradition. It's really just the same old song.
      • Content
      • Means lumps leftist politics in South conservative European politics. He doesn't see them as fundamentally different, both follow the same exploitative and destructive logic
  10. Feb 2023
    1. [Episode!]! represents an array of Episode objects. Since it is also non-nullable, you can always expect an array (with zero or more items) when you query the appearsIn field. And since Episode! is also non-nullable, you can always expect every item of the array to be an Episode object.

      Note that this still allows an empty array, []. It only disallows: null and [null].

    1. Strip unsafe tags, leaving behind only the inner text. Prune unsafe tags and their subtrees, removing all traces that they ever existed. Escape unsafe tags and their subtrees, leaving behind lots of < and > entities. Whitewash the markup, removing all attributes and namespaced nodes.
  11. Jan 2023
    1. click_link('Create Account', match: :first) It's better than first(:link, 'Create Account').click as it will wait till at least one Create Account link will appear on the page. However I believe it's better to choose unique locator that doesn't appear on the page twice.
    1. There's a fundamental error in your question: commits are not diffs; commits are snapshots. This might seem like a distinction without a difference—and for some commits, it is. But for merge commits, it's not.
  12. datatracker.ietf.org datatracker.ietf.org
    1. Unlike access tokens, refresh tokens are intended for use only with authorization servers and are never sent to resource servers.

      Interesting observation...

  13. Dec 2022
    1. whereas division implies separation (“portion,” “piece,” “unit”) diversity implies variety within a whole (“assortment,” “heterogeneity”)
    1. Mailgun, with its permanent failure webhook, is sending a message about a permanent failure of that specific message - it is Campaign that is then making a decision to translate this message, about just that one message, into a permanently bounced (suppressed) contact, and blocking all future emails to that contact - based on, what is clearly quite possibly just a temporary failure. It's really the distinction between a single message level (temporary) problem and a (permanent) contact level problem that is being lost with Campaign's current approach.
  14. Nov 2022
    1. Note: The ? method will return false if a key has been set to false or nil. In order to check if a key has been set at all, use the mash.key?('some_key') method instead.
    1. Remember there are two kinds of variable. Internal Variables and Environment Variables. PATH should be an environment variable.

      In my case, I was trying to debug which asdf not finding asdf, in a minimal shell.

      I had checked bash-5.1$ echo $PATH|grep asdf /home/tyler/.asdf/bin

      but ```

      The PATH environment variable

      env | /bin/grep PATH `` being empty was the key discovery here. Must have forgotten theexport`.

    2. All shells should tell you that your path is the same thing with BOTH of the two commands: # The PATH variable echo "$PATH" # The PATH environment variable env | /bin/grep PATH
    1. Changing the second line to: foo.txt text !diff would restore the default unset-ness for diff, while: foo.txt text diff will force diff to be set (both will presumably result in a diff, since Git has presumably not previously been detecting foo.txt as binary).

      comments for tag: undefined vs. null: Technically this is undefined (unset, !diff) vs. true (diff), but it's similar enough that don't need a separate tag just for that.

      annotation meta: may need new tag: undefined/unset vs. null/set

    1. First, if Jenkins runs as PID 1, then it's difficult to differentiate between process that were re-parented to Jenkins (which should be reaped), and processes that were spawned by Jenkins (which shouldn't, because there's other code that's already expecting to wait them).
    1. Zombie processes should not be confused with orphan processes: an orphan process is a process that is still executing, but whose parent has died. When the parent dies, the orphaned child process is adopted by init (process ID 1). When orphan processes die, they do not remain as zombie processes; instead, they are waited on by init.
    1. At one time the replacement character was often used when there was no glyph available in a font for that character. However, most modern text rendering systems instead use a font's .notdef character, which in most cases is an empty box (or "?" or "X" in a box[5]), sometimes called a "tofu" (this browser displays 􏿾). There is no Unicode code point for this symbol.
    2. 2.^ Grey areas indicate non-assigned code points 3.^ Black areas indicate noncharacters (code points that are guaranteed never to be assigned as encoded characters in the Unicode Standard)
    3. Since the replacement is the same for all errors this makes it impossible to recover the original character. A better (but harder to implement) design is to preserve the original bytes, including the error, and only convert to the replacement when displaying the text. This will allow the text editor to save the original byte sequence, while still showing the error indicator to the user.
    1. While there are many great answers regarding the "glyph not found" glyph, that won't help you actually detect it, as the text string in code will still have the character regardless of the font used to render it.
    2. By the way, I am not talking about � (replacement character). This one is displayed when a Unicode character could not be correctly decoded from a data stream. It does not necessarily produce the same glyph:
    3. replacement glyph missing glyph interpretable but unrenderable character
    4. it does not have a fixed glyph, though fonts that contain it tend to use very similar glyphs
    1. Characters are logical text units identified by Unicode codepoints, whereas glyphs are graphical font units. The distinction between character and glyph is critical to understanding FontLab, and fonts in general.
  15. Oct 2022
    1. Now that we have seen this implementation, you might be wondering what is the use case for having two #initialize_* methods. The answer is: there is another way to copy objects, called #clone. You generally use #clone if you want to copy an object including its internal state. This is what Rails is using with its #dup method on ActiveRecord. It uses #dup to allow you to duplicate a record without its "internal" state (id and timestamps), and leaves #clone up to Ruby to implement.
    2. An interesting fact here is that Rails deliberately chose to override the #initialize_dup method instead of the #initialize_copy method. Why would it do that? Let's investigate.
  16. Sep 2022
    1. “Internationalization is the design and development of a product, application or document content that enables easy localization for target audiences that vary in culture, region, or language. Localization refers to the adaptation of a product, application or document content to meet the language, cultural and other requirements of a specific target market (a locale).”
    1. First, to clarify - what is "code", what is "data"? In this article, when I say "code", I mean something a human has written, that will be read by a machine (another program or hardware). When I say "data", I mean something a machine has written, that may be read by a machine, a human, or both. Therefore, a configuration file where you set logging.level = DEBUG is code, while virtual machine instructions emitted by a compiler are data. Of course, code is data, but I think this over-simplified view (humans write code, machines write data) will serve us best for now...
    1. 400 Bad Request is the status code to return when the form of the client request is not as the API expects.401 Unauthorized is the status code to return when the client provides no credentials or invalid credentials.403 Forbidden is the status code to return when a client has valid credentials but not enough privileges to perform an action on a resource.
    1. I think the answer lies here: Cant see into oneOf or allOf etc. This, I think, is the distinguishing difference between additionalProperties and unevaluatedProperties.
    2. We do not want to change or remove additionalProperties. Providing a clear solution for the above use case will dramatically reduce or eliminate the misunderstandings around additionalProperties.

      annotation meta: may need new tag: - don't want to change or remove existing feature [because...] - solving problem B will reduce misunderstandings around feature A

  17. Aug 2022
    1. I recommend using the term “parallel” when the simultaneous execution is assured or expected, and to use the term “concurrent” when it is uncertain or irrelevant if simultaneous execution will be employed.
    2. Concurrency is about dealing with lots of things at once. Parallelism is about doing lots of things at once.
    3. A system is said to be concurrent if it can support two or more actions in progress at the same time. A system is said to be parallel if it can support two or more actions executing simultaneously.
    4. Concurrency means executing multiple tasks at the same time but not necessarily simultaneously.
    1. you can also replicate the bind:this syntax if you please: Wrapper.svelte <script> let root export { root as this } </script> <div bind:this={root} />

      This lets the caller use it like this: <Wrapper bind:this={root} />

      in the same way we can already do this with elements: <div bind:this=

  18. Apr 2022
    1. Caution: + continues the statement but not the string. puts "foo"+"bar".upcase gives you fooBAR, whereas puts ("foo"+"bar").upcase gives you FOOBAR. (Whether or not there's a newline after the +.) But: if you use a backslash instead of the plus sign, it will always give you FOOBAR, because combining lines into one statement, and then combining successive strings into one string, happen before the string method gets called.
    1. These callbacks are smart enough to run after the final (outer) transaction* is committed. * Usually, there is one real transaction and nested transactions are implemented through savepoints (see, for example, PostgreSQL).

      important qualification: the outer transaction, the (only) real transaction

    1. (Note this is NOT post.comments.order... we don’t know what post, yet. We want the final query to return comments, so our filter starts with Comment.)
    1. If I create a model ActiveRecord sends NULL values for every field that is not defined. Postgres dutifully writes the NULL value into the field instead of the default value. Activerecord should either send nothing (preferable) or send DEFAULT.
  19. Mar 2022
    1. Use apt as a first choice, but if you're scripting use apt-get. Apt-get has more stable output (meaning that the output format is left alone as much as possible so as not to break scripts which parse that output automatically). Apt-get also has some low-level commands not available in apt.
    1. Object hierarchies are very different from relational hierarchies. Relational hierarchies focus on data and its relationships, whereas objects manage not only data, but also their identity and the behavior centered around that data.
    1. Note that this is a breaking API change in the libraries (more information in the README.md). It does not affect the backwards compatibility of the protocol itself.

      annotation meta: may need new tag: backwards compatibility of the protocol backwards compatibility for [libraries that use [it?]]

  20. Feb 2022
    1. "Context" manipulation is one of big topic and there are many related terminologies (academic, language/implementation specific, promotion terminologies). In fact, there is confusing. In few minutes I remember the following related words and it is good CS exam to describe each :p Thread (Ruby) Green thread (CS terminology) Native thread (CS terminology) Non-preemptive thread (CS terminology) Preemptive thread (CS terminology) Fiber (Ruby/using resume/yield) Fiber (Ruby/using transfer) Fiber (Win32API) Generator (Python/JavaScript) Generator (Ruby) Continuation (CS terminology/Ruby, Scheme, ...) Partial continuation (CS terminology/ functional lang.) Exception handling (many languages) Coroutine (CS terminology/ALGOL) Semi-coroutine (CS terminology) Process (Unix/Ruby) Process (Erlang/Elixir) setjmp/longjmp (C) makecontext/swapcontext (POSIX) Task (...)
  21. Jan 2022
    1. As said in the chapter, there’s an "implicit try..catch" around the function code. So all synchronous errors are handled. But here the error is generated not while the executor is running, but later. So the promise can’t handle it.
    1. Fundamentally, I think promise rejection is substantially different than "throwing" under normal synchronous flow.
    2. but has a critical difference: the expression console.log("before 2"); does not and cannot depend on the resolved value result. The throw propagates through all chained promises, and when it stops, there is no remaining undefined behavior! No piece of code is left in an unclear state, and therefore there is no reason to crash.
    1. Meaning if you have your own roll-your-own login process and never use HTTP Authentication, 403 is always the proper response and 401 should never be used.
    2. So, for authorization I use the 403 Forbidden response. It’s permanent, it’s tied to my application logic, and it’s a more concrete response than a 401. Receiving a 403 response is the server telling you, “I’m sorry. I know who you are–I believe who you say you are–but you just don’t have permission to access this resource. Maybe if you ask the system administrator nicely, you’ll get permission. But please don’t bother me again until your predicament changes.”
    1. Indicates that though the request was valid, the server refuses to respond to it. Unlike the 401 status code, providing authentication will not change the outcome.
    1. I used the word "intended" behavior, because that is the behavior im looking for, but I may not be expressing it correctly in Svelte. It may not be the expected behavior of the code.
    2. For me there is a distinct difference between these two scripts: let a = 1; $: b = a * 2; let a = 1; let b; $: { b = a * 2 }; The first example defines a "recipe" for how to create b and b is completely defined by that declaration. Outside of that it is immutable, data flows only into a single sink. The second example declares a variable b and then uses a reactive statement to update it. But it also allows you to do with b whatever you want. If someone wants to go that route (definitely not me), they are free to do so at their own risk of ensuring consistency.
  22. Dec 2021
    1. [Vote!]! means that the field (in this case votes) cannot return null and that it must resolve to an array and that none of the individuals items inside that array can be null. So [] and [{}] and [{foo: 'BAR'}] would all be valid (assuming foo is non-null). However, the following would throw: [{foo: 'BAR'}, null] [Vote]! means that the field cannot return null, but any individual item in the returned list can be null. [Vote!] means that the entire field can be null, but if it does return a value, it needs to an array and each item in that array cannot be null. [Vote] means that the entire field can be null, but if it does return a value, it needs to an array. However, any member of the array may also be null.
  23. Nov 2021
    1. The type-fest package contains only types, meaning they are only used at compile-time and nothing is ever compiled into actual JavaScript code. This package contains functions that are compiled into JavaScript code and used at runtime.
  24. Oct 2021
    1. The hasOwnProperty() method returns a boolean indicating whether the object has the specified property as its own property (as opposed to inheriting it).
    1. Inflections go the other way around.In classic mode, given a missing constant Rails underscores its name and performs a file lookup. On the other hand, zeitwerk mode checks first the file system, and camelizes file names to know the constant those files are expected to define.While in common names these operations match, if acronyms or custom inflection rules are configured, they may not. For example, by default "HTMLParser".underscore is "html_parser", and "html_parser".camelize is "HtmlParser".
    2. it does not belong to the autoload paths by default but it belongs to $LOAD_PATH
  25. Sep 2021
    1. A sanitary tee is shaped like the letter ‘T’, while a Wye is similar to ‘Y’. Sanitary tee is used for horizontal to vertical transition, and Wye is used for combining 2 lines into one horizontal line to maintain a flow without causing clogging.
    2. Sanitary Tee and Wye are parts of the drain vent system. If you are doing plumbing works, you may have to use them in some sort. However, they look almost similar, and this confuses a lot of people. Especially to choose the one that best fits your drain system.
    1. If your configuration is not provided by a name server (like the information given in /etc/hosts) those tools will not show them, because they directly ask the name server.
    1. A controller is the entity that determines the purposes and means of the processing of personal data. Some examples of a controller are listed below.DigitalOcean is a controller for our customer’s personal data (e.g. personal information provided to DigitalOcean when signing up for our services)A DigitalOcean customer may be a controller if they collect and process personal data on their customers (e.g. personal data provided to you by your customers)A processor is the entity that processes personal data on behalf of another entity. An example of a processor is listed below.DigitalOcean is a processor for our customer’s end-user personal data (e.g. A DigitalOcean customer stores their customer’s personal data on a DigitalOcean service)
    1. Generally, shrank is the simple past tense form of "shrink" like in "I shrank the shirt in the wash." Shrunk is the past participle being paired with "have" as in "I have shrunk the jeans." There are rarer examples of shrinked and shrunken in literature but not enough to support those usages as standard.
    1. When referring to a change in direction, position, or course of action, the correct phrase is to change tack. This is in reference to the nautical use of tack which refers to the direction of a boat with respect to sail position. This phrase has long been confused as "change tact" but this is technically incorrect.
    1. svelte-preprocess doesn't do any kind of type-checking, it just transpiles your ts into js (see it here). If you want to fail your build when a type error is found, you can use svelte-check.
    1. This particular project has a differentiation between a package's app/ folder and the current project's app/ folder.
    1. Gems use a period and packages use a dot

      Probably a false distinction, because "packages" is used in a way that it implies a distinction from "gems", when in actuality

      1. gems are packages, too (Ruby packages)
      2. it's referring specifically to JavaScript/node/npm packages,

      ... so there is only truly a distinctio if you are specific enough to say JavaScript packages.

    1. But it is always important to remember that those are not language concepts. Those are community concepts that only exist in our heads and in the names of some library methods.

      I'm not sure about this. I get what he's saying and agree that singleton methods are nothing but a naming convention for the more fundamental/atomic construct called instance methods (which indeed are the only kind of method that exist in Ruby, depending how you look at it), but I think I would actually say that singleton methods are language concepts because those methods like Object#define_singleton_method, ... are always available in Ruby (without needing to require a standard library first, for example). In other words, I would argue that something belonging in the Ruby core "library" (?) by definition makes it part of the language -- even if it in turn builds on even lower-level Ruby language features/constructs.

    2. Note: when I wrote above that "there is no such thing as X", what I meant was that "there is no such thing as X in the Ruby language". That does not mean that those concepts don't exist in the Ruby community.
  26. Aug 2021
    1. As with any classification there's a fuzzy line between them (Rake could be thought of either way.)
    2. When people talk about internal DSLs I see two styles: internal minilanguages and language enhancements.
  27. Jul 2021
    1. You would get a return value of the type "string" | "number" | "boolean" | "symbol" | "undefined" | "object" | "function", because you're using the JavaScript typeof operator at runtime, which returns a string like "object", not the compile-time type seen by TypeScript.
  28. Jun 2021