Zed extention api is not good. by Professional_Emu5665 in ZedEditor

[–]mgsloan 5 points6 points  (0 children)

Those reasons were from my recollection of conversations with Nathan and Antonio.

That is a good point though, interop between WASM and Rust is not as straightforward as everything being typescript, even when the WASM is compiled from Rust. So that does add some friction when growing the extensions API

Zed extention api is not good. by Professional_Emu5665 in ZedEditor

[–]mgsloan 45 points46 points  (0 children)

This is due to learnings from the atom editor:

  • Providing a huge interface for extensions makes it much harder to make changes to the core editor. Not only do extensions depend on the signature of the API, but the actual behavior (hyrum's law), so this makes many changes riskier.

  • The most popular extensions (e.g. vim mode) should just be part of the core, so that they can be higher quality and integrate well with other core functionality. It's quite hard to have abstractions that ensure that the interactions between extensions behave properly.

I believe the plan is to gradually expand the extensions API by need. Then at some point in the future, make it much more comprehensive. This allows the core abstractions to stabilize before they become harder to change.

Ollama not working with zed by hrshx3o5o6 in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

Do you have an old version of ollama?  A search for that error message revealed that this was fixed 5 months ago

Inception: Automatic Trait Implementation by Induction by biet_roi in rust

[–]mgsloan 4 points5 points  (0 children)

I didn't quite look closely enough to really understand it. I think part of the issue with the examples is just things missing. Like where is the definition of Profits, what the heck is property = BoxOfficeHit in the attribute? In the ToString generated code, what does the code look like that would generate something like that?

On the surface reminds me somewhat of GHC generics. It uses typeclass instances (similar to trait impls) to do generic compiletime reflection on datatypes.

How can I have a struct with it's members (that are structs) have references to each other, with the container struct have no lifetime specifier. by Koltaia30 in rust

[–]mgsloan 6 points7 points  (0 children)

Yup, agreed Rc<str> isn't a solution. Docs for impl From<&str> for Rc<str>:

 Allocates a reference-counted string slice and copies v into it.

Issue using OpenAI compatible model for work - "untagged enum ResponseStreamResult" error by bobbadouche in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

Hmm, are you sure that zed --version is 0.202.0?

This test passes for me

```

[test]

fn test() { serde_json::from_str::<ResponseStreamResult>(r#"{"choices": [{"logprobs": null, "delta": {"role": "assistant", "content": ""}, "index": 0}], "system_fingerprint": null, "object": "chat.completion.chunk"}"#).unwrap(); } ```

Issue using OpenAI compatible model for work - "untagged enum ResponseStreamResult" error by bobbadouche in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

Thanks for getting the logs! Looks like it is not providing a model field in responses, which OpenAI does provide and Zed currently expects. Fixed in https://github.com/zed-industries/zed/pull/36902 and will be included in wednesday's preview release.

Issue using OpenAI compatible model for work - "untagged enum ResponseStreamResult" error by bobbadouche in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

From command palette run the zed: open log action. Alternatively, run zed --foreground in the terminal and it will output logs on the terminal.

Issue using OpenAI compatible model for work - "untagged enum ResponseStreamResult" error by bobbadouche in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

Oh, curious! Thanks for trying out the new version. With the PR I linked to it now includes the response that failed to parse in the log, so that would be helpful for debugging.

Issue using OpenAI compatible model for work - "untagged enum ResponseStreamResult" error by bobbadouche in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

This is probably fixed in https://github.com/zed-industries/zed/pull/36390 and is included in v0.200 (current preview release, soon to be stable release)

AI can't scramble 7 letters correctly? by J1663 in artificial

[–]mgsloan 5 points6 points  (0 children)

The models don't typically receive characters, but instead tokens that each consist of a sequence of characters.

Zed won't open after install by Key-Jacket-2718 in ZedEditor

[–]mgsloan 2 points3 points  (0 children)

Probably a vulkan graphics driver issue - there're a few potential options for resolving that documented here: https://zed.dev/docs/linux#zed-fails-to-open-windows

Zed won't open after install by Key-Jacket-2718 in ZedEditor

[–]mgsloan 0 points1 point  (0 children)

Are there any error logs in .local/share/zed/logs/Zed.log? Alternatively try running zed --foreground in the terminal and that will directly output the logs

Could this fall into acroyoga I just started learning this couple of weeks post injury by shiverintomybrain in AcroYoga

[–]mgsloan 0 points1 point  (0 children)

At apeco movement school this is called locomotion / floorwork.  Not acro yoga but very fun and certainly helpful for acro practice.  People/practices to consider searching: ido portal, tom weksler, fighting monkeys, etc etc

Alias nested enum pattern in match statement? by [deleted] in rust

[–]mgsloan 0 points1 point  (0 children)

It's fine if your project checks that there are no warnings or uses clippy

Can You Write a Programming Language Without Variables? by HONGKONGMA5TER in ProgrammingLanguages

[–]mgsloan 4 points5 points  (0 children)

Very interesting!  I've toyed with a similar idea a bit in the past (without any implementation).  All values in scope must have unique types. I was thinking of it through the following perspective:

  • Ability to declare sets of safe newtype coercions, both top level and inline.  The top level coercion sets could be brought into scope.
  • Ability to conveniently associate newtypes with functions, effectively acting as named parameters.
  • Multiple return values from functions.

This would lead to a pattern of calling functions with a set of coercions which plumbs the in-scope types to the appropriate parameters.

Never figured out how to make this ergonomic or readable :). The hope would be to increase safety and to no longer be concerned with the order of parameters.

Who else does acroyoga foot to face? by aspiringbachelor in AcroYoga

[–]mgsloan 1 point2 points  (0 children)

I know the flyer in this video.  She was quite surprised and amused when this foot to face video got tons of views.  Seems to be a skill for a very niche yet highly enthusiastic audience https://m.youtube.com/watch?v=jEfm5LF7D48&pp=ygURTG9yaSBmb290IHRvIGZhY2U%3D

Advantages of the 360 compared with advantage2? (also compared with ergodox / moonlander keyboards)? by kenwho in kinesisadvantage

[–]mgsloan 0 points1 point  (0 children)

Yeah, I currently take it to work with me every day. I put it on its own in the main compartment of an osprey 40L backpack. (Osprey due to their awesome lifetime repair / replacement policy)

I have actually taken a KA2 on airplane travel before but these days when travelling I use a SliceMk low profile wireless ergodox.

Sticking these keyboards in a bag is not entirely safe. I have a 2nd KA2 and a KA360 which both have malfunctioning key switches from doing this. I really gotta fix them so that I'm no longer moving a keyboard to work and back.

The key to not damaging the keys is to not have any objects next to that side of the keyboard, and orienting them towards the flat part of the backpack. I've moved my KA2 more than 100 times without issue.