HN user

janci

1,157 karma
Posts3
Comments336
View on HN

My reasons to hate XML:

- element vs attribute ambiguity

- model of the document does not fit nicely to programming model of structs, dicts and arrays

- too many complexities (entities, cdata, parser directives)

- cardinality unknown without schema (is that a single value, or an array that just happens to have one element)

- order of elements may or may not be significant depending on schema

- not really extensible if the original schema does not explicitly allow for extensibility

- some types of valid XML documents are not representable by a schema (e.g. any number of different elements in any order)

- verbosity

- namespace identifiers being URIs that may or may not be resolvable

What I want for general data exchange is JSON with comments and sane namespaces.

Edit: line wraps

As a kid I was intrigued by telephones. I got hands on two old rotary phones and I wanted them to talk together. I wired them in series with a battery. Despite my dad telling me it never gonna work - it kinda worked. You could hear the other side just well! It just did not ring.

I've made a great effort in making the phones ring. At that time I did not know it needs 90V (fortunately - I'd probably hurt myself). I figured out it needs AC, but how do you produce AC with only a battery? I even made a hack to rapidly reverse polarity using a relay in self-oscillating mode, only to get shocked by the induced voltage by the relay coil and no ring.

(Now I see that maybe if I used the coil voltage it would actually ring!)

This great article brought back nice memories of tinkering with the phones.

The assumption is the adversary controls x of N nodes. When x=N the probability of discovering the onion service IP is 1. But the adversary can not achieve this situation as he only controls the additional nodes. The existing nodes still stay in the network, they do not disappear. The ratio is not x/N but x/(x+N).

The formula is wrong and it all falls apart.

I think it is a tradeoff between "everybody can request age verification" and "only state-licensed parties can request age verification". I don't think everybody's ID card should tell anyone if the holder is adult or not, especially wirelessly

Our state-issued eID cards are supposed to have a function that allows anonymous age verification to a trusted party. It should work like this: a requesting party sends a request signed by state-issued certificate to the ID card, the card verifies the request authenticity and responds with a signed confirmation of legal age and that signature then can be verified by the requester.

No personal information is shared.

While I do not aggree with pervasive age restrictions, this is a nice technical solution to privacy preserving age verification

Yet, Google is a lot more specific im what, how and why you license the content to Google. And it is not for anything that Firefox does.

Plus:

Some of our services are designed to let you upload, submit, store, send, receive, or share your content. You have no obligation to provide any content to our services and you’re free to choose the content that you want to provide.

We need a license to allow us to make some of the basic functionality of Firefox possible. Without it, we couldn’t use information typed into Firefox, for example.

Like - what basic functionality? Does not sound like "browsing" is that functionality and I am not interested in any other functionality. I do not want you (Mozilla organization) to use any of that information.

Moreover, what if I do not have the right to sublicense the content I enter to FF? Am I legally not allowed to use Firefox?

Delphi Is 30 1 year ago

I did not do many things in Delphi but I have studied the language and VCL architecture for the very purpose of determining why it is so aproachable and productive (as compared to C, Java, JS, Python and the tooling around them).

In my opinion, it is the result of following qualities:

1. The language direcly supports concepts needed for live WYSIWYG editing (i.e. properties and events) while other languages only simulate it by convention (i.e. Java Bean specification)

2. The language syntax is simple enough for the IDE to understand and modify programatically, but powerful. The properties files that define the forms are even simpler, support crucial features (i.e. references and hierarchy) but do not bring unecessary complexity as general-purpose formats do (XML files or JSON)

3. Batteries included - you can do very powerful stuff with the included components (gui, i/o, ipc, sql, tcp/ip, graphics - all the practical stuff) without hunting for libraries

4. Discoverability - the visual component paradigm with Property editor lets you see all your possibilities without reading the documentation.

5. Extensibility - you can build your own components that fully integrate with the IDE. This is my litmus test for low-code and RAD tools: For any built-in feature, can I recreate the same using the provided tools? Many tools fail this, and the built-in components can do things that are inaccessible to user-defined components.

6. Speed - both compilation and runtime, thanks to one-pass compilation and native code. Leads to fast iteration times.

7. The VCL component architecture is a piece of art. The base classes implement all the common functionality: They automatically manage memory, can store and load persistent state, have properties for visual placement (position, size) etc. The language features really help here (I remebmer something about interface delegation) but there is no magical runtime that does this from the outside, it's an actual implementation of the component that can be extended or overriden.

But of couse there are the ugly things as well: alien syntax, forward declarations, strict compiler blocking the Form Designer on any error preventing you to fix the very error and most of all: while there is very good abstraction for the components, there is none for data and state. There is no good tooling for data modelling and working with the data models. That leads to poor practices as having state in the visual components or in global variables.

I just flip the coin cell around so it stays in the device but does not deplete (reverse polarity but in fact the contacts will not touch the battery poles so no harm).

Honest question as I don't know almost anything about modern computer graphics: Is it so much performance penalty to upload a small texture to GPU so you can't render the whole string to the texture in 2D and just display the texture onto two triangles?

Some operations are best with keyboard (i.e. moving, zooming, panning, duplicating, acessing panels) and you need modifier keys quite often. You can map one or two to the stylus buttons, but that may not be sufficient

Sshfs for Windows 2 years ago

While still useful to have a native tool, you can use WSL to mount a sshfs path in windows. I even use it for LUKS containers.

3. You can only call a red function from within a red function

The base of most arguments against async. And it's false. You can call red from blue. And you should, sometimes.