#Semantic Satiation
1 messages ยท Page 1 of 1 (latest)
when a phrase is repeated so much it loses meaning
Ah right
Semantic satiation is a psychological phenomenon in which repetition causes a word or phrase to temporarily lose meaning for the listener, who then perceives the speech as repeated meaningless sounds. Extended inspection or analysis (staring at the word or phrase for a long time) in place of repetition also produces the same effect.
so what we were doing was a lot of:
`container.With(WithSomeCommonFeature), and he noticed our functions used With redundantly, which yep, we fix that.
then I look at how a bunch of steps in a row look:
return GoBuildBase(client).
With(debian.AddPackages("docker")).
With(InstallMage()).
With(ShellStep("cd /usr/local/; curl -L https://dl.dagger.io/dagger/instal_l.sh | sh")).
WithEntrypoint([]string{"/bin/sh", "-s"})
Yeah, I hear you. With() is a stopgap until we ship a more powerful composition model.
For one, it's SDK-specific.. Unlike all the other calls, With() doesn't exist in the GraphQL schema. Each SDK has to manually add its own.
we came up with this shape:
func Compose(funcs ...dagger.WithContainerFunc) dagger.WithContainerFunc {
return func(container *dagger.Container) *dagger.Container {
for _, fn := range funcs {
container = container.With(fn)
}
return container
}
}
and do something like this:
return GoBuildBase(client).
With(Compose(
debian.AddPackages("docker"),
InstallMage(),
ShellStep("cd /usr/local/; curl -L https://dl.dagger.io/dagger/instal_l.sh | sh"))).
WithEntrypoint([]string{"/bin/sh", "-s"})
we're just a team obsessed with defining language around our concepts, so we're all pretty weird about the shape of apis. sorry.
Don't worry you're in good company ๐
Did you take a look at #daggernauts yet?
Should be right up your alley
I will probably end up getting up to speed on it, and yeah it is interesting. I really need to get a po submitted for the cache service
Re: cache service, are you in touch with Lev? (head of solutions) He can help navigate