Skip to content

deprecate: mark FreeStyle Libre and planned workout functions as deprecated#15

Open
terra-alex wants to merge 2 commits into
mainfrom
deprecate/fsl-glucose-functions
Open

deprecate: mark FreeStyle Libre and planned workout functions as deprecated#15
terra-alex wants to merge 2 commits into
mainfrom
deprecate/fsl-glucose-functions

Conversation

@terra-alex

@terra-alex terra-alex commented Mar 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds @Deprecated annotations to the following functions in lib/terra_flutter_bridge.dart:

FreeStyle Libre

  • readGlucoseData()
  • activateGlucoseSensor()

Planned Workouts

  • postPlannedWorkout(connection, payload)
  • getPlannedWorkouts(connection)
  • deletePlannedWorkout(connection, id)
  • completePlannedWorkout(connection, id, at)

No logic changes — annotation only. Dart analyzer will show deprecation warnings for these functions.

🤖 Generated with Claude Code

terra-alex and others added 2 commits March 2, 2026 18:38
Add @deprecated annotations to readGlucoseData and activateGlucoseSensor
in TerraFlutter. These methods will be removed in a future release.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@terra-alex terra-alex changed the title deprecate: mark FreeStyle Libre glucose functions as deprecated deprecate: mark FreeStyle Libre and planned workout functions as deprecated Mar 3, 2026
@gemini-code-assist

Copy link
Copy Markdown

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request initiates the deprecation process for specific FreeStyle Libre glucose-related functions within the TerraFlutter class. By applying @Deprecated annotations to activateGlucoseSensor and readGlucoseData, the change signals to developers that these methods are no longer recommended for use and will be removed in a future update. This provides consumers with compile-time warnings, allowing them to proactively migrate their code.

Highlights

  • Deprecation of FreeStyle Libre Glucose Functions: The activateGlucoseSensor and readGlucoseData methods in TerraFlutter have been marked as deprecated using the @Deprecated annotation.
  • Future Removal: These functions are being phased out and are slated for removal in a future release, providing advance notice to consumers.
  • No Logic Changes: The pull request introduces no changes to the existing logic; only deprecation annotations were added.
Changelog
  • lib/terra_flutter_bridge.dart
    • Marked activateGlucoseSensor() with @Deprecated annotation.
    • Marked readGlucoseData() with @Deprecated annotation.
Activity
  • No human activity has occurred on this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request correctly deprecates the FreeStyle Libre functions readGlucoseData() and activateGlucoseSensor(). However, it does not deprecate the planned workout functions as stated in the description. Please add the @Deprecated annotation to postPlannedWorkout, getPlannedWorkouts, deletePlannedWorkout, and completePlannedWorkout to complete the changes as intended. I have also left a minor suggestion to improve code clarity.

})));
}

@Deprecated('This method is deprecated and will be removed in a future release.')

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

For consistency with readGlucoseData and to improve clarity, please add a comment indicating that activateGlucoseSensor is also an Apple-specific function. This will help prevent confusion and potential runtime errors on other platforms like Android where it is not implemented.

  // only for apple
  @Deprecated('This method is deprecated and will be removed in a future release.')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant