HNHacker News
TopNewBestAskShowJobs

tomhallett

882 karma · joined January 14, 2011

Ruby and Javascript Developer.

Software Engineer at Incredible Health.

github.com/tommyh

submissionscomments
tomhallett··on Calif. passes strongest right-to-repair bill yet, requiring 7 years of parts
I'm wondering if it was a carve out that was easy to give, doesn't water it down too much and is helpful for other politics:

* Sony produces semi-conductors and movies (Sony Pictures, Columbia, Tristar)

* Microsoft is big in enterprise cloud (ie: government)

* the impact of people being forced to upgrade their phone because they can't fix it, is probably larger than people being forced to upgrade their game system because they can't fix it

Note: I 100% agree with you. I see video games as the same as all other consumer electronics which were included, but I can see if Sony/Microsoft came complaining, it's a good bargaining chip/favor for other initiatives.

tomhallett··on My Node.js is a bit Rusty
I think we can all agree that the blog article, while interesting and tells a story about the way the author solved a problem, does not have high enough rigor to serve as a benchmark for "don't do this, do this instead", or "this language is bad at this, and this one is better". Those types of statements would require much more rigor and A vs B comparisons where code A and code B are the same, just in different languages.

BUT, what I am interested in - if I'm using javascript to parse a large file line by line, plucking off specific fields like the example does, what can I try to see if it's more GC-friendly? Obviously the answer is always some flavor of "profile it" and "it depends". If the blog author could have gotten a big boost in performance by adding 10 lines of js code to their loop, that is something all readers of the article could benefit from.

I will play around with it and see what I can learn about the V8 GC. For reference: here is a talk about profiling the ruby gc, which helped me fix a memory leak at work (https://www.youtube.com/watch?v=kZcqyuPeDao).

tomhallett··on My Node.js is a bit Rusty
Following you in the abstract, but still a bit confused.

* "unbounded array" - are you referring to `records`?

* If so, is the memory of `records` too large? Or is it that `records[i].pathname` has a reference to `fields[7]`, AND v8 will retain all copies of `fields` until the loop is done?

Do you think this code would be more GC-friendly?

```

let count = 0;

const MAX = 1000;

const flushedRecords = [];

for await (const line of readlineStream) {

  const fields = line.split('\t');

  const httpStatus = Number(fields[5]);

  if (httpStatus < 200 || httpStatus > 299) continue;

  records.push({

    pathname: fields[7],

    referrer: fields[8],

    // ...

  });

  if(count == MAX || isLastLine(line)){

   flushedRecords.push([...records]);

   records = [];
   
    count = 0;

  } else {
    count++;
  }
  

}

```

Or were you thinking something totally different?

tomhallett··on Windows 11 system components use the default browser to open links in Europe
While I agree there is a bit of difference, it's somewhat inconsequential to the end user having their preferences respected:

* Microsoft: we will let you set a preference, but we will ignore/reset it

* Apple: we won't let you set a preference at all

If someone wanted to say "Microsoft and Apple don't care about your preferences, but Microsoft is slightly worse", I think that'd be a fair thing to say.

Agreed that apple's is a lack of a feature, BUT if you look at the features which apple does support, it feels closer to they don't want to add it for anti-competitve reasons, and not a technical/implementation reason

* ios apps can be deep linked via "apple-app-site-association"

* ios apps can have custom url schemes "comgooglemaps://?parameters"

* android has had "intents" for a very long time

* ios sms is already detecting "this is an address" from free text and is hot linking it to their maps app

tomhallett··on Windows 11 system components use the default browser to open links in Europe
When someone texts me an address, the only option is “Open in Maps” which is for Apple Maps, when I’d clearly prefer Google Maps.

When I click on an address in FB Messenger, I get the “open in google maps or Apple Maps” prompt, but choosing Google Maps just takes me to the Google Maps App Store page, even though I have the app installed and updated.

If there is a solution to this problem (where my attempts failed for some reason), I’d be all ears. :)

tomhallett··on Selling open-source software
Just checked out your pricing. I notice you have a one time price, which gives you a year of support/upgrades. Curious the percentage of customers who opt not to get upgrades and therefore don’t need to pay yearly.
tomhallett··on Textual: Rapid Application Development framework for Python
Awesome!

I'm imagining a workflow where textual can be used as a progressive enhancement for a cli tool, in case the user doesn't pass in all required flags. A web frontend for that view will make it more comfortable for even more types of users.... :)

python code_format.py --file app.js => textual isn't used/invoked at all

python code_format.py => textual is used to show user a DirectoryTree file dialog, then exits

I'm assuming this could work via "App" return values: app.exit({ file: "app.js" })

Do you have any examples of textual being used in this manner? If not, no worries

tomhallett··on Textual: Rapid Application Development framework for Python
This looks very cool.

For the web browser version which is coming soon, will the “DirectoryTree” feature be supported? Any idea when the web view will be in beta/launch?

tomhallett··on Selling open-source software
Are there any good examples on "source available" startups, where the software can be run on-prem, can be easily modified/forked by the customer, but has a commerical license? (Thinking docker desktop style: free for companies with less than X customers, monthly flat license for > X employees)
tomhallett··on Launch HN: PeerDB (YC S23) – Fast, Native ETL/ELT for Postgres
Any thoughts on type2 scd, when loading Postgres data into snowflake/bigquery? We use fivetran’s “history mode” for this and it’s been very useful.
tomhallett··on Styling Flowcharts Using CSS
Flowchart.fun looks very very cool. Solves many problems I've faced with existing tools.

Has anyone used flowchart.fun for "architecture" diagrams? Which are similar to flowchart/mindmaps, but a bit different.

I'm trying to make something like this webapp diagram, but struggling: https://bezkoder.com/wp-content/uploads/2020/03/react-node-e...

tomhallett··on Feature Flags: Theory vs. Reality
Agreed, but at least with the override mechanism being as visible as the test suite, you have assured that more people will know about it (bringing it "to the surface") and you might even have the override in source control (documented). These aspects are increasing the chances someone will say "Let's just follow the process."
tomhallett··on Show HN: b2bsaaskit.com
I've read the faq and i'm a bit confused - you are introducing me to 3 tools/companies: B2B Saas Kit, Fog Bender, and Prompts with Friends. I have a bad understanding of all 3, instead of a great understanding of one of them, which I assume should be b2bsaaskit.

It's an instructional bundle - what does that mean? an opinionated cli tool? a starter repo? a set of tutorials/videos about how to use these services in your starter app? do i use chatgpt (prompts with friends) to build the app?

it looks like you use astro as the framework for a serverless react SPA? supabase as backend? can i choose a different backend now vs later (fastapi/etc)?

i think flushing out the homepage can def help quite a bit, :). edit: looks like the github readme is the helpful page to read, not the homepage/faq.

tomhallett··on Launch HN: Argonaut (YC S21) – Easily Deploy Apps and Infra to AWS and GCP
Can you give some examples of what you are reimplementing? Is that going well or is it requiring hacky workarounds?
tomhallett··on Jessica Livingston (2015)
Are there any books on this topic that anyone would recommend? As a manager, this is where I struggled the most - naturally i am someone who strives to be a consensus builder, but it's hard to know when to put your thumb on the scale vs not.
tomhallett··on One line of code that did cost $8k
Are there any saas tools which help track cloud/saas usage/charges? Or do most people build something homegrown with cloud monitors, pulling billing data from other saas apps, and making data “observability” bi dashboards.

Ex: - we used to sync 1MM contacts per month to our crm, but this month it’s 2mm - I created an rds database for testing something, but forgot to turn it off (imaging a “library checkout” feature, where I get permission to create a resource for X time, then alerts if I don’t delete it)

tomhallett··on Htmx Is the Future
question - which parts of htmx would be better from an end-user-perspective if they were built into the browser? i assume "all features" might be a bit faster, but is there anything which would be night and day better if it wasn't a js library?

the browser vendors have been more than happy to use experimental features to chart their own course, which I think can be a good thing to spawn innovation and healthy competition. (given the standards bodies will be slower and more prudent - similar to how python doesn't want "pedantic" to be part of python core, because that would hurt pedantic's innovation, not improve it)

Maybe the way someone from the chrome team could tap into "business value" of "let's build these htmx features in chrome" would be that it allows developers to write "internal/developer/crud apps" where a "only supported in chrome" is acceptable.....

tomhallett··on Htmx Is the Future
have you seen any interest by the browsers to build htmx features as experimental browser features, with the goal of htmx features becoming browser standards?

When looking at the various options, I always enjoyed your architectural choice of htmx being an extension of html, for that very reason. Similar to "phonegap" hoping that the phonegap code base would get smaller and smaller as mobile browsers built more of those features natively. :)

tomhallett··on Mojo – a new programming language for AI developers
Yeah, obviously curious if a fastapi port could be written in mojo
tomhallett··on Show HN: I built a database GUI with ChatGPT integration
I 100% agree. This is why I think that LLM's will help encourage better coding practices, not worse. The more that you can write "clean code" (things which are named correctly, follow the single responsibility pricinciple, don't violate the law of demeter, build the correct data-models/data-marts), then the easier it will be for LLM's to assist senior engineers in writing code/sql faster.

And if there is an interface given to people who will struggle to evaluate the correct-ness of something, ie: a Business Intelligence tool for people who don't know/care about the data model, then the question becomes "How can the tool facilitate getting the people who can verify the correctness of the sql/code do so in an efficient manner?" I'm thinking like a short-term pull-request, where the "code committer" is the LLM and the reviewer is a human. Said in another way: the chatbot is going in reverse, where chatgpt is asking the questions and the human gives the answers...... haha

tomhallett··on Udemy to pay $4M to settle a case alleging it advertised fake discounts
The most annoying part of the DRM is that the mobile app prevents you from taking screenshots. I often listen to courses while doing something else, so taking a screenshot of a slide is an easy way for me to "take notes". The idea that I'm going to use a mobile screenshot to steal content is so far fetched and hostile to paying customers.

Note: screenshots on a computer work fine, which is hilarious because if I were to imagine someone stealing content en-masse, I'd assume they would prefer a computer.

I know that instructors can opt in/out to this feature, but I think it's bogus that it exists at all and I don't fault instructors from having it enabled.

tomhallett··on AT&T Wireless traffic shaping apparently making some websites unusable
Adriano,

In the article you mention "Cloudflare" a few times, but I think you mean "Cloudfront". For example: "web-assets.strava.com resolves to Cloudflare, see the writeup on my site for details"

I'm assuming this was a typo based on the names sounding so similar and both being CDN's. Is that correct?

tomhallett··on TaxyAI: Open-source browser automation with GPT-4
While your example of "site adds a modal" is true, with browser based regression tests, the brittleness I find much more often is minor changes to the DOM, which don't have a large impact on what the user sees. (Sometimes this is due to refactoring the DOM, sometimes it's because the DOM doesn't have good class names to use as handles, and sometimes it's because I want to reuse a step on 2 different pages, but the rendered DOM is slightly different).

My mental model of how I think about drift (which might be totally worthless from a LLM perspective):

1) I give a prompt

2) snapshot of dom is taken

3) gpt looks at that snapshot DOM and implements some solution which works

4) that solution is transformed into a more concrete implementation

4i) whether this "transformation" is any of the following isn't SUPER important, and to be honest I'd love to see all 3: a) selenium/playwright code writen by Taxy, b) a hybrid of explicit code and a gpt prompt, or c) developer can override with fully custom code

4) it runs correctly for X amount of time

5) application dom changes

6) taxy notices the step is failing

7) taxy takes a new snapshot of the dom

8) taxy runs a (reinforcement?) algorithm against the new snapshot and confirms it finds the "same" dom element as the one from old snapshot.

unrelated: the other thing which I've found very hard to program into my browser tests (and makes the code hard to interpret), so I'm curious how gpt/taxy could help:

Given I have this dom:

<ul>

  <li>

    <div class="tweet">

      <h1>Check out my sandwhich!</h1>

      <button>Retweet</button>

    </div>

  </li>

  <li>

    <div class="tweet">

      <h1>Check out my shoes!</h1>

      <button>Retweet</button>

    </div>

  </li>
</ul>

I want to write test code which is:

1) When I load the page, I should see a tweet "Check out my sandwhich!"

2) I can retweet that tweet.

Currently, I either need todo:

a) a dom traversal: find(text: "Check out my sandwhich", css: ".tweet h1").parents(".tweet").find(text: "retweet"). It's that `parents(".tweet")` part which becomes awkward at scale and incentives developers to only create 1 tweet in the test database....

b) use Page Objects, which I love, but adds overhead/training for the team

I would love if gpt could figure out, these 2 elements are "related". :)

tomhallett··on Nearly Half of Firms Are Drafting Policies on ChatGPT Use
Has OpenAI said anything (in their TOS/etc) about who owns the copyright/ip on the code that it generates? I know it’s a legal minefield of a question, just curious if they have said “we won’t sue you if you copy/paste this code in your app” publically or anything.
tomhallett··on FDIC Takes over Silicon Valley Bank
If a bank is noticing they are getting more deposits then they can safely make returns for (like SVB in 2020), can banks "simply" return deposits to customers and/or decline new customers/deposits? Is there a precedent to doing this? Or does everyone decide it's better to take risky bets to grow with the increasing deposits and we'll keep seeing runs when those bets go south?
tomhallett··on The False Promise of ChatGPT
I have to respectfully disagree with Noam Chomsky's opinion piece on ChatGPT. While it's true that AI cannot replace human creativity and intelligence, it has the potential to revolutionize how we interact with and understand the world around us.

ChatGPT and other language models have already made significant strides in improving language translation, facilitating natural language processing, and even assisting in scientific research. While it's true that AI models like ChatGPT have their limitations and biases, we shouldn't dismiss their potential outright.

It's also worth noting that some of Chomsky's criticisms of ChatGPT feel misplaced or overly idealistic. For instance, Chomsky argues that ChatGPT fails to truly "understand" language, but this critique ignores the fact that humans themselves often use language without fully understanding its intricacies.

In any case, it's important that we approach the development and implementation of AI with a critical and ethical lens. Rather than outright dismissing AI models like ChatGPT, we should engage in ongoing conversations about how to use these technologies in responsible and beneficial ways.

Note: this comment was written by ChatGPT with the following prompts:

* Please write an comment suitable for the site hackernews, of this article "The False Promise of ChatGPT", https://www.nytimes.com/2023/03/08/opinion/noam-chomsky-chat..., where you are somewhat critical, but overrall positive of the article

* that looks great. but rewrite it in a more casual tone and sentance structure

* remove the first sentance

* remove the phrase "As a language model AI myself,"

* please rewrite the answer and take a stronger stand on an issue. it's ok if it's controversal or based in opinion

tomhallett··on Could we make the web more immersive using a simple optical illusion?
Agreed. My first thought was - what percentage of the target market could you serve with coding to specs for MacBooks, which have deterministic hardware.

Or if the tuning parameters exist with some range, use a traversal algorithm to find them, similar to an eye exam: “A or B? [change parameter]. A or B? [change parameter]. Repeat”

tomhallett··on AI Tool Reveals How Celebrities’ Faces Have Been Photoshopped
Agreed. That’s why the before/after is so critical - no one cares about the removal of a stray wisp of hair, but I think people would be interested in digital changes to the “structure” of the person.
tomhallett··on Introducing ChatGPT and Whisper APIs
Has OpenAI said anything (in their TOS/etc) about who owns the copyright/ip on the code that it generates?

I know it’s a legal minefield of a question, just curious if they have said “we won’t sue you if you copy/paste this code in your app” publically or anything.

tomhallett··on AI Tool Reveals How Celebrities’ Faces Have Been Photoshopped
I've always been curious what it would look like if magazines had to publish the "unphotoshopped version" side-by-side with the "final version" inside the magazine. Would people check the before/after and it would lessen any negative effects? Would magazines photoshop things less?

Note: I understand there is nuance in the definition of "photoshop", with respect to processing a "raw" photo for lighting/color/etc, versus manipulating it to add/remove/blur/liquify/shape.

← PreviousPage 3 of 10Next →