먼 미래에는 어떻게 될 지 잘 모르겠지만, 일단 코딩 에이전트한테 LSP를 툴로 쥐어 줘야 하는 게 아닌가 하는 생각이 요즘 많이 든다.
洪 民憙 (Hong Minhee)
@hongminhee@hackers.pub · 959 following · 674 followers
Hi, I'm who's behind Fedify, Hollo, BotKit, and this website, Hackers' Pub! My main account is at
@hongminhee洪 民憙 (Hong Minhee)
.
Fedify, Hollo, BotKit, 그리고 보고 계신 이 사이트 Hackers' Pub을 만들고 있습니다. 제 메인 계정은:
@hongminhee洪 民憙 (Hong Minhee)
.
Fedify、Hollo、BotKit、そしてこのサイト、Hackers' Pubを作っています。私のメインアカウントは「
@hongminhee洪 民憙 (Hong Minhee)
」に。
Website
- hongminhee.org
GitHub
- @dahlia
Hollo
- @hongminhee@hollo.social
DEV
- @hongminhee
velog
- @hongminhee
Qiita
- @hongminhee
Zenn
- @hongminhee
Matrix
- @hongminhee:matrix.org
X
- @hongminhee
Claude Code가 다 좋은데, Claude 모델들이 죄다 콘텍스트 윈도가 짧아가지고 금방 오토 컴팩션이 도는 탓에, 그러고 나면 하던 걸 죄다 까먹고 갑자기 바보가 된다…
AI에 대한 SW 엔지니어들의 자신감은 "어쨌거나 업계 내에서 만드는거라서-" 인거 같다. 손바닥 위에 있다는 감각(얼추 맞긴 하다).
타 직업군은 AI나 LLM 솔루션 자체를 다루는데도 한계가 있거니와(아무래도 fork떠서 고친다거나 할순 없으니까) 결과물도 자기 의사와 관계 없이 학습당하고 있기 때문에…
아예 거스를 수 없는 것이기 때문에, 타 분야에서는 오히려 공격적으로 자기 분야에 특화된 모델을 만들고, 기존 저작물들을 학습으로 부터 보호해서 우선권을 선점 하는게 그나마 좀 더 낫지 않을까?
근데 후자는… 테크기업이 양아치라서 잘 안될거같다.
Next.js 서버 액션은 서버 데이터를 가져오는 용도로 사용하기에 적합하지 않다. React 공식문서에서는 다음과 같이 말하고 있다.
Server Functions are designed for mutations that update server-side state; they are not recommended for data fetching. Accordingly, frameworks implementing Server Functions typically process one action at a time and do not have a way to cache the return value.
서버 액션이 여러 호출되면 바로 실행되는 대신 큐에 쌓이고 순차적으로 처리된다. 이미 실행된 서버 액션은 이후 취소할 수 없다.
이에 서버 액션을 데이터 가져오기로 활용하면 끔찍해지는 UX가 생길 수 있는데, 예를 들어 페이지의 목록 검색 화면에서 검색 후 데이터를 가져오는 상황에 않았다고 다른 화면으로 네비게이션이 불가능한 것은 일반적인 경험이 아니다.
이러면 RSC를 통해 무한 스크롤을 구현하지 못하는가? 에 대해서 의문이 생길 수 있는데 여기에 대해서 대안을 발견했다.
function ServerComponent({ searchParams }) {
const page = parseInt((await searchParams).page ?? "1", 10)
const items = await getItems(page)
return (
<Collection id={page}>
{items.map(item => <InfiniteListItem key={item.id} {...items} />)}
</Collection>
)
}
"use client"
function Collection({ id, children }) {
const [collection, setCollection] = useState(new Map([[id, children]]))
const [lastId, setLastId] = useState(id)
if (id !== lastId) {
setCollection(oldCollection => {
const newCollection = new Map(oldCollection)
newCollection.set(id, children)
return newCollection
})
setLastId(id)
}
return Array
.from(collection.entries())
.map(
([id, children]) => <Fragment key={id}>{children}</Fragment>
)
}
대충 이런 꼴이다. 이러고 page를 증가시키거나 감소시키는건 intesection observer나 특정 엘리먼트의 onClick 이벤트 따위를 의존하면 된다. 이러면 데이터 가져오기 패턴을 RSC 형태로 의존할 수 있다. InfiniteListItem는 서버컴포넌트, 클라이언트컴포넌트 무엇으로 구현하더라도 상관없다. 가령 아래와 같은 식:
function ServerComponent({ searchParams }) {
const page = parseInt((await searchParams).page ?? "1", 10)
const { items, hasNext } = await getItems(page)
return (
<div>
<Collection id={page}>
{items.map(item => <InfiniteListItem key={item.id} {...items} />)}
</Collection>
{hasNext && (
<IntersectionObserver nextUrl={`/?page=${page + 1}`} />
)}
</div>
)
}
검색 조건이나 검색어에 따라 상태를 초기화시키려면 다음과 같이 표현하면 된다.
function ServerComponent({ searchParams }) {
const page = parseInt((await searchParams).page ?? "1", 10)
const query = parseInt((await searchParams).query ?? "")
const { items, hasNext } = await getItems(page, query)
return (
<div>
<Form action="/">
<input name="query" />
<button />
</Form>
<Collection id={page} key={query}>
{items.map(item => <InfiniteListItem key={item.id} {...items} />)}
</Collection>
{hasNext && (
<IntersectionObserver nextUrl={`/?page=${page + 1}&query=${query}`} />
)}
</div>
)
}
매우 PHP스럽고, 암묵적이기도 하다. 다만 RSC의 데이터 가져오기 패턴을 활용하면서 기존 컴포넌트를 최대한 재사용할 수 있게 된다는 점이 좋다.
실제로 방금 어떤 사례를 발견했냐면, 계산이 살짝 까다로운 값에 대한 테스트를 만들라고 시켰더니 코드를 한 백줄 뱉어내는데
expect(x).toBe(42)
이렇게 값에 대한 테스트를 안하고
expect(typeof x).toBe("number")
이러고 넘어가려고 했다. 손바닥 이리내.
실제로 방금 어떤 사례를 발견했냐면, 계산이 살짝 까다로운 값에 대한 테스트를 만들라고 시켰더니 코드를 한 백줄 뱉어내는데
expect(x).toBe(42)
이렇게 값에 대한 테스트를 안하고
expect(typeof x).toBe("number")
이러고 넘어가려고 했다. 손바닥 이리내.
@bglbgl gwyng 맞아요. 아마도 실세계에 이런 테스트 코드가 많기 때문에 더 그러는 게 아닐까 싶습니다… ㅋㅋㅋ
性能がいいマシンがメインのRTX積んでるやつしかないのでLLM動かすのはここじゃないと難しそう🤔
@cocoaAmaseCocoa LLMはGPUの性能も重要ですが、VRAMの容量も多く必要なので、最近ではLLMの研究者の間でMac mini M4の統合RAM容量を最大にアップグレードしたモデルが最もコスパが良いと言われているようです。
안녕하세요, 숫자상입니다.
@numberer58숫자상 반갑습니다, 어서 오세요!
Hackers' Pub은 기본 Markdown 문법 외에 다양한 확장 문법을 지원합니다. TeX을 통한 수식, 각주, 경고 박스(admonitions), 표, Graphviz를 통한 도표, 코드 블록에서 특정 줄만 강조하기 등…
마땅한 기술 블로깅 플랫폼을 못 찾았다면, Hackers' Pub도 고려해 보세요!
@hongminhee洪 民憙 (Hong Minhee) Isn't that FEP based on the GTS spec? If it's notably worse, I guess that says something about the process
@TakTak!
@hongminhee洪 民憙 (Hong Minhee) it's the other way around, FEP-5624 pre-dates GTS' interaction policies but was never implemented anywhere and did not get much traction; the bulk of the discussion at the time was about who should control the reply policy (original post author or person you immediately reply to)
GTS decided to pick the second solution even if it's not necessarily the ideal one, because it's much simpler to implement
GTS' interaction policies were then refined with a lot of back-and-forth with Mastodon devs when we were working on quote posts (resulting in FEP-044F which re-use GTS' interaction policies)
maybe we should retire FEP-5624
@hongminhee洪 民憙 (Hong Minhee) Yeah, but I mean it's the mastodon-driven proposal to "generalize" the existing gts system
@TakTak! Hmm, but I feel it's rather regressed from GoToSocial's spec. 😅
@hongminhee洪 民憙 (Hong Minhee) Isn't that FEP based on the GTS spec? If it's notably worse, I guess that says something about the process
@TakTak! I have no idea, but I guess it's from Mastodon because it depends on toot: namespace? 🤔
join을 지원하는 reactive한 SQLite client 개발 거의 다 되어간다. 혹시 중간에 관두는걸 막기위해 남긴다.
@hongminhee洪 民憙 (Hong Minhee) I guess GtS should probably add their implementation to the FEP!
@liaizonwakest ⁂ Yeah, I left my thoughts on my separate post:
After reviewing FEP-5624: Per-object reply control policies and GoToSocial's interaction policy spec, I find myself leaning toward the latter for long-term considerations, though both have merit.
FEP-5624 is admirably focused and simpler to implement, which I appreciate. However, #GoToSocial's approach seems to offer some architectural advantages:
- The three-tier permission model (allow/require approval/deny) feels more flexible than binary allow/deny
- Separating approval objects from interactions appears more secure against forgery
- The explicit handling of edge cases (mentioned users, post authors) provides clearer semantics
- The extensible framework allows for handling diverse interaction types, not just replies
I wonder if creating an #FEP that extracts GoToSocial's interaction policy design into a standalone standard might be worthwhile. It could potentially serve as a more comprehensive foundation for access control in #ActivityPub.
This is merely my initial impression though. I'd be curious to hear other developers' perspectives on these approaches.
#FEP5624 #fedidev #fediverse #replycontrol #interactionpolicy
There would be some potential downsides to consider though:
- Performance overhead: Each interaction requires policy verification, and approval object dereferencing adds network latency.
- UX complexity: The three-tier permission model (allow/approve/deny) might confuse users compared to simpler binary choices.
- State management burden: Servers need to persistently store approval objects and handle revocation edge cases gracefully.
After reviewing FEP-5624: Per-object reply control policies and GoToSocial's interaction policy spec, I find myself leaning toward the latter for long-term considerations, though both have merit.
FEP-5624 is admirably focused and simpler to implement, which I appreciate. However, #GoToSocial's approach seems to offer some architectural advantages:
- The three-tier permission model (allow/require approval/deny) feels more flexible than binary allow/deny
- Separating approval objects from interactions appears more secure against forgery
- The explicit handling of edge cases (mentioned users, post authors) provides clearer semantics
- The extensible framework allows for handling diverse interaction types, not just replies
I wonder if creating an #FEP that extracts GoToSocial's interaction policy design into a standalone standard might be worthwhile. It could potentially serve as a more comprehensive foundation for access control in #ActivityPub.
This is merely my initial impression though. I'd be curious to hear other developers' perspectives on these approaches.
#FEP5624 #fedidev #fediverse #replycontrol #interactionpolicy
@hongminhee洪 民憙 (Hong Minhee) has no one written a FEP for reply controls yet?!
@liaizonwakest ⁂ Oh, there's FEP-5624: Per-object reply control policies! However, I find GoToSocial's interaction policy spec more well-designed. 🤔
我认为 ActivityPub 应该实现到 GoToSocial 级别(
@dwndiaowinner GoToSocial's interaction policy spec is pretty well designed, but from an implementer's perspective, there's so much to do that it can feel a bit overwhelming. 🥲
我认为 ActivityPub 应该实现到 GoToSocial 级别(
Pixelfed의 경우에는 commentsEnabled라는 단순한 불리언 타입의 속성을 정의해서 쓰고 있는데, 문서화는 안 되어 있다. 음, 그냥 이걸 구현하면 일이 쉬워질 것 같지만… 한다면 제대로 GoToSocial의 상호작용 방침 기능을 구현하고 싶기도 한데.
댓글 막기 옵션을 구현하려고 했더니, 연합우주에서 댓글을 막았다는 것을 나타내는 합의된 속성 같은 게 없는 것 같다. 내가 멋대로 어휘를 하나 정해서 써도 되겠지만… 음…
댓글 막기 옵션을 구현하려고 했더니, 연합우주에서 댓글을 막았다는 것을 나타내는 합의된 속성 같은 게 없는 것 같다. 내가 멋대로 어휘를 하나 정해서 써도 되겠지만… 음…
<section> 버리고 <article> 써야 하는 이유 #a11y
〈section〉태그 안의 글에 헤딩(제목)을 포함하면 화면상에서는 그 헤딩들이 논리적인 순차 구조를 가지고 있는 것처럼 보인다. 하지만 이는 순전히 시각적인 것일 뿐 보조 기술과 연동된 구조 정보가 아니다.〈section〉태그의 용도는 무엇이고, 헤딩을 어떻게 코딩해야 보조 기술 사용자에게 정말 중요한 구조 정보를 전달할 수 있을까?
@iamuhun김무훈 인용한 글의 태그에 쓰인 괄호가 U+003C LESS-THAN SIGN 및 U+003E GREATER-THAN SIGN이 아니라 U+3008 LEFT ANGLE BRACKET 및 U+3009 RIGHT ANGLE BRACKET이군요…
@ailrunAilrun (UTC-5/-4) LLM 요약 대신 글 앞 부분을 보여주는 옵션을 설정에 만들어 보도록 하겠습니다. 😅
@ailrunAilrun (UTC-5/-4) 옵션을 추가했습니다! 설정 → 환경 설정 → AI가 생성한 요약 선호 옵션을 해제하시면 됩니다.
무접점은, 키가 끝까지 눌리지 않도록 쓰는 습관을 꼭 들여야 할 것 같은데, 쉬운 습관이 아닌 것 같아요. 전 아직 갈축이 주 키고, 서브로 적축을 적축답지 않게 때려가며 쓰고 있어요.
@hongminhee洪 民憙 (Hong Minhee)
@lionhairdino 요즘 무접점 키보드들은 키를 얼만큼 눌러야 누른 것으로 볼 지를 설정하는 기능이 있더라고요!
요 며칠 리니어 스위치가 달린 기계식 키보드 쓰다가 방금 정전용량 무접점 키보드로 바꿔보았다. 이건 이것대로 타건감이 좋아서 기분 전환이 되는 듯!
남한에서 '핵추진잠수함'이라 하는 것을 북한에서 '핵동력잠수함'이라 하는 것이 문득 떠오르네요.
RE: https://hackers.pub/ap/notes/01969960-f7e6-7b4f-8acf-3daecae56241
글에 대한 AI 요약이 생겼는데 AI 요약을 혐오하는 사람으로서는 약간 당황스럽다 😅
@ailrunAilrun (UTC-5/-4) LLM 요약 대신 글 앞 부분을 보여주는 옵션을 설정에 만들어 보도록 하겠습니다. 😅
Hackers' Pub에 글 올릴 때 도표를 Graphviz로 그리면 좋은 점: 도표 안의 글자도 함께 번역된다!
.vscode/settings.json으로 확장 켜고끌수 없나 찾아봤는데 해당 이슈가 8년째 오픈이란걸 알게되었다.
Hackers' Pubに興味はあるけれど、DMで招待状をお願いするのは気が引けるという方のために、Googleフォームを作成しました。メールアドレスを入力するだけで、Hackers' Pubの招待状をお送りします。たくさんのご応募をお待ちしています‼️
똑같은 인터페이스에 대한 여러 구현체에 대해 같은 테스트를 적용하기위한 좋은 방법이 뭘까요? vitest의 경우에 test.each(implementations) 이런식으로 할수 있다는데, 이러면 구현체가 늘어났을때 테스트 파일을 수정해야하는점이 마음에 안든단 말이죠. 지금 구현체를 인자로 받아 테스트를 정의하는 함수를 만들고 각 구현체 마다 .test.ts파일을 만들어서 호출하는 방식을 고려하고 있습니다. 더 좋은 방법이 있을까요?
@bglbgl gwyng 저도 비슷하게 했던 것 같아요.
プロンプト組むのが下手な可能性もある
@cocoaAmaseCocoa Hackers' Pubでは、LLMベースの翻訳に以下のようなプロンプトを使用しています。
あー。drizzleって、PostgreSQLlのmoney(通貨型)はまだサポートしてないのか。なるほど、試さないと分からないもんだ。他の型で代用するか。
書籍「テスト駆動開発」か「リファクタリング第二版」でいうプログラムだけでなく、データベースもリファクタリングの対象にするというか、将来に向かって現在動くものを作る感じなんだな。これも。
현재 Hackers' Pub은 Fresh 2.0 알파 버전을 사용하고 있는데, Fresh 자체의 한계점도 많이 느꼈고 무엇보다 최근 몇 달 사이에 정식 릴리스를 향한 진전이 보이지 않기에 GraphQL 준비가 끝나면 프런트엔드를 SolidStart로 점진적으로 옮겨가고자 한다.
Hackers' Pub 저장소의 CONTRIBUTING.md 내 사용하는 기술 목록에 Pothos와 Yoga도 추가했다. 나중에 저기서 Fresh를 빼고 SolidStart를 넣는 날이 오겠지…!?
MisskeyでフォローしてAccept送って202返ってきたのにフォローが処理中になってうまくフォローしたことにならない...
@cocoaAmaseCocoa MisskeyにもActivityPub.Academyの様なデバッグ用のインスタンスが欲しいですね。🥲
오늘도 해커스펍 GraphQL API 깎기 해야지
아까 Post에 달린 이모지 리엑션 쪽 API 깎느라고 n시간 동안 삽질하다가 결국 때려치고 질문을 올렸었는데 아직 구현이 안 된 부분이었다고 해서 PR을 올렸다 (???
SolidJS는 React처럼 Reactivity 코어가 분리되어 있지않은거 같다? solid-three, solid-native 등의 프로젝트들이 있는데 2년넘게 관리되고 있지않다.
@bglbgl gwyng 커스텀 렌더러 (Solid에선 Universal Rendering이라고 부름) 지원 자체는 잘 되어 있는데 그냥 커뮤니티 망치가 부족해서 유지보수가 안 되는 것에 가깝고 😅 이런 물건은 왜인진 도저히 모르겠지만 나름 관리가 잘 되고 있습니다
캘린더 이벤트로 변환이 가능한 데이터들 (예약 서비스의 예약 내역, 캘린더 양식이 아니어서 변환이 필요한 데이터, 매우 낮은 에러 레이트 리밋(?) 같은 이유로 인하여 일반적인 캘린더 동기화에 넣기 불안한 출처)를 모아다가 주로 사용하는 캘린더 서비스로 보내주는 서비스를 만들려고 합니다.
프로젝트 이름 예쁘게 짓는 방법 구합니다
프로젝트 이름 예쁘게 짓는 방법 구합니다
@perlmint 저는 영어 이외의 언어에서 관련된 단어를 찾아보는 편입니다.
SolidJS는 React처럼 Reactivity 코어가 분리되어 있지않은거 같다? solid-three, solid-native 등의 프로젝트들이 있는데 2년넘게 관리되고 있지않다.
招待してもらったのでhackers.pubに出たり入ったりした→
@cocoa@hackers.pubAmaseCocoa
大文字小文字混ぜると問題起こる気がしたのでわざと@cocoaにした (そもそもこっちが正式ではなくもない)
print("Hello World")
@cocoaAmaseCocoa ここあさん、Hackers' Pubへようこそ‼️
print("Hello World")




