DiamondLightSource / DiamondLightSource/atlas

InstrumentSessionView should return a Visit object

Open
#156 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1
Forks
4
Avg merge
6d 8h
Merged PRs (30d)
8

Description

Currently the `instrumentSession` provided by the component made in https://github.com/DiamondLightSource/atlas/pull/129/changes gives a string of the full session. However, it is often useful for queries to break this into proposal/sessionNumber (https://github.com/DiamondLightSource/atlas/pull/150/changes/BASE..db987190745743f998993c53c0261e472e5699dc#r3748402923). We already have a Visit object that holds the session split into parts, we should pass this around instead of the raw string

## Acceptance Criteria
* A new `fullStringRepresentation` field is added to `Visit`
* The `instrumentSession` returns a `Visit`
* Uses of the `instrumentSession` grab out of the `Visit` the data they need
* We rename `Visit` to `Session` to maintain consistency?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at InstrumentSessionView and trace where its instrumentSession value is created and consumed. Read the existing Visit object and its callers, then update the consumers to use the split session data and verify that instrumentSession returns a Visit with fullStringRepresentation; resolve whether the Visit-to-Session rename is in scope.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
62/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.