Skip to content

Server thing descriptions have wrong href for affordances #221

@julianstirling

Description

@julianstirling

Describe the bug
The Thing Descriptions for each thing is fine. However when creating the Thing Descriptions for the server the affordance hrefs are modified with path put in as the first argument which is read from the key in the things dictionary. This is now the name not the path of the Thing.

This means that the href is written into the server thing description as "href": "camerabackground_detector_data", not "href": "camera/background_detector_data"

As the OpenFlexure Microscope uses the server thing_description for every action and property url, nothing works in the webapp.

To Reproduce
Create any LabThings server. Go to http://127.0.0.1:5000/thing_descriptions/ look at the hrefs

Expected behaviour
Correct hrefs. hrefs tested in unit tests.

System:

  • OS: Kunbuntu 24.04
  • Python version: 3.11
  • Version: 0.0.12

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions