Skip to content
This repository has been archived by the owner on Nov 19, 2020. It is now read-only.

Series type #56

Merged
merged 15 commits into from
Nov 25, 2019
Merged

Series type #56

merged 15 commits into from
Nov 25, 2019

Conversation

kylebrandt
Copy link
Contributor

@kylebrandt kylebrandt commented Nov 20, 2019

@kylebrandt
Copy link
Contributor Author

Basic Idea: non-pointer type is a proper subset its pointer type (nullable type), i.e. float64 ⊂ *float64

  • Series gets a nullableTime property which reflects if the time Vector is a slice time.Time or *time.Time.
  • Getters always return pointers
  • Setters always take pointers, and set the appropriate type (will error if an attempt to set nil to a series with non null-nullable.
  • nonPointer Op nonPointer = nonPointer, pointer Op nonPointer = pointer (or switched), pointer Op pointer = pointer

Is this actually what I did ...

@kylebrandt kylebrandt marked this pull request as ready for review November 25, 2019 15:13
go.mod Outdated
github.com/google/go-cmp v0.3.1
github.com/grafana/grafana-plugin-sdk-go v0.2.0
github.com/grafana/grafana-plugin-sdk-go v0.2.1-0.20191120150621-555ae32d7580
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs sdk pr merged, then this updated

@kylebrandt
Copy link
Contributor Author

I don't know that it is fair to ask for a review on this ... is quite large, moved some tests around. This tests are still a mess, I need to make a scenario matrix of some sort and figure out how they should be structured. Currently just continuing some debt.

I think after Frame.Labels -> Frame.Field.Labels is probably a good time to do that.

Main changes are type_series. Some TODOs are left in there but I am okay with that.

@kylebrandt kylebrandt merged commit 19dcd6b into master Nov 25, 2019
@kylebrandt kylebrandt deleted the seriesType branch November 27, 2019 17:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant