Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Type 'TooltipTriggerMode' not found. final TooltipTriggerMode? triggerMode #42

Closed
abhipoojary opened this issue Dec 6, 2021 · 4 comments

Comments

@abhipoojary
Copy link

app is working in debug mode, but its throwing several errors when i try to build the APK. Bellow i will mention the errors which i got.

`../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:80:9: Error: Type 'TooltipTriggerMode' not found.
final TooltipTriggerMode? triggerMode;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:288:16: Error: Type 'TooltipTriggerMode' not found.
static const TooltipTriggerMode _defaultTriggerMode =
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:300:8: Error: Type 'TooltipTriggerMode' not found.
late TooltipTriggerMode triggerMode;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip_entry.dart:60:9: Error: Type 'TooltipTriggerMode' not found.
final TooltipTriggerMode? triggerMode;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/models/just_the_interface.dart:125:3: Error: Type 'TooltipTriggerMode' not found.
TooltipTriggerMode? get triggerMode;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:289:7: Error: Getter not found: 'TooltipTriggerMode'.
TooltipTriggerMode.longPress;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:80:9: Error: 'TooltipTriggerMode' isn't a type.
final TooltipTriggerMode? triggerMode;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:288:16: Error: 'TooltipTriggerMode' isn't a type.
static const TooltipTriggerMode _defaultTriggerMode =
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:300:8: Error: 'TooltipTriggerMode' isn't a type.
late TooltipTriggerMode triggerMode;
^^^^^^^^^^^^^^^^^^
../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:559:26: Error: The getter 'TooltipTriggerMode' isn't defined for the class '_JustTheTooltipState'.

  • '_JustTheTooltipState' is from 'package:just_the_tooltip/src/just_the_tooltip.dart' ('../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'TooltipTriggerMode'.
    if (triggerMode == TooltipTriggerMode.longPress) {
    ^^^^^^^^^^^^^^^^^^
    ../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:581:44: Error: The getter 'triggerMode' isn't defined for the class 'TooltipThemeData'.
  • 'TooltipThemeData' is from 'package:flutter/src/material/tooltip_theme.dart' ('../../src/flutter_2.2.3/packages/flutter/lib/src/material/tooltip_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'triggerMode'.
    widget.triggerMode ?? tooltipTheme.triggerMode ?? _defaultTriggerMode;
    ^^^^^^^^^^^
    ../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:583:22: Error: The getter 'enableFeedback' isn't defined for the class 'TooltipThemeData'.
  • 'TooltipThemeData' is from 'package:flutter/src/material/tooltip_theme.dart' ('../../src/flutter_2.2.3/packages/flutter/lib/src/material/tooltip_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'enableFeedback'.
    tooltipTheme.enableFeedback ??
    ^^^^^^^^^^^^^^
    ../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:590:29: Error: The getter 'TooltipTriggerMode' isn't defined for the class '_JustTheTooltipState'.
  • '_JustTheTooltipState' is from 'package:just_the_tooltip/src/just_the_tooltip.dart' ('../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'TooltipTriggerMode'.
    : (triggerMode == TooltipTriggerMode.longPress)
    ^^^^^^^^^^^^^^^^^^
    ../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart:595:29: Error: The getter 'TooltipTriggerMode' isn't defined for the class '_JustTheTooltipState'.
  • '_JustTheTooltipState' is from 'package:just_the_tooltip/src/just_the_tooltip.dart' ('../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'TooltipTriggerMode'.
    : (triggerMode == TooltipTriggerMode.tap)
    ^^^^^^^^^^^^^^^^^^
    ../../src/flutter_2.2.3/.pub-cache/hosted/pub.dartlang.org/just_the_tooltip-0.0.10/lib/src/just_the_tooltip_entry.dart:60:9: Error: 'TooltipTriggerMode' isn't a type.
    final TooltipTriggerMode? triggerMode;
    ^^^^^^^^^^^^^^^^^^

FAILURE: Build failed with an exception.

  • Where:
    Script '/home/mindstack/src/flutter_2.2.3/packages/flutter_tools/gradle/flutter.gradle' line: 1035

  • What went wrong:
    Execution failed for task ':app:compileFlutterBuildRelease'.

Process 'command '/home/mindstack/src/flutter_2.2.3/bin/flutter'' finished with non-zero exit value 1

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org
    `

@stargazing-dino
Copy link
Owner

stargazing-dino commented Dec 13, 2021

Sorry for late response. I think around Flutter 2.3 (?) introduced TooltipTriggerMode to keep track of how a tooltip is shown. This package just follows the standard tooltip implementation with small added stuff on top so it looks like just a version mismatch somewhere. Perhaps you are building prod for a different version somehow? Really not sure

I currently test against the dev and stable branch of Flutter where all tests are currently passing but let me know if there's something I'm missing

@Vidtion
Copy link

Vidtion commented Jan 6, 2022

same on flutter 2.2.3

@Bes79
Copy link

Bes79 commented Jan 28, 2022

save issue on flutter 2.8.1

@stargazing-dino
Copy link
Owner

Sorry guys, I'm closing this. I test against against stable and beta and they both support TooltipTriggerMode. Your issue is very likely related to just using an older version of flutter than the two I test against. Feel free to reopen another issue with further details and we can have another look

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

No branches or pull requests

4 participants