I’ve been working on (yet another) Lemmy app for the fun of it but I had a question come to mind with the new v0.18.0 announcement.

Since it is up to the instance admins to update the server, how should Client developers handle instances across Lemmy having different API version numbers with potential incompatibilities?

There are a few existing libraries but it seems the change from v0.17.4 to v0.18.0 is proving cumbersome for at least one library and most likely others as well.

Any thoughts?

  • impulse@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    My best guess would be to require a minimum version of Lemmy and for example keep the app backwards compatible with the last two versions.

    Since Lemmy is rapidly evolving, expections to this rule of thumb would probably become necessary, if bigger changes are rolled out by the devs.

  • fmstrat@lemmy.nowsci.com
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Check the version via API? IMO breaking changes should change the versioned API URL (which I think they do), but developers will need to adjust for each instance by determining it’s version first.

    Hopefully as things mature this won’t be as much of a problem.

  • mesamune@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    I have no idea how they are currently doing it, but in app development, it’s quite common to add the api version into the api call and use that within a client app. You just make sure the major versions are covered and then have a minimum version you support. It will heavily depend on if the app makers support sysver or not.