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

method 'markNeedsBuild' isn't defined for the class 'RenderConstrainedLayoutBuilder<Constraints, RenderObject>' #2045

Open
chirastefan opened this issue Aug 29, 2024 · 9 comments
Labels
charts Charts component waiting for customer response Cannot make further progress until the customer responds.

Comments

@chirastefan
Copy link

Bug description

Error (Xcode): ../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_charts-26.2.11/lib/src/charts/cartesian_chart.dart:1367:22: Error: The method 'markNeedsBuild' isn't defined for the class 'RenderConstrainedLayoutBuilder<Constraints, RenderObject>'.

version ^26.2.11

Steps to reproduce

install that version and try to run a dart project locally using ios simulator iPhone 11 Pro

Code sample

Code sample
  void _buildTrackballWidget(List<TrackballDetails> details) {
    final TrackballBehavior trackballBehavior = widget.trackballBehavior!;
    final List<ChartPointInfo> chartPointInfo =
        trackballBehavior.chartPointInfo;
    if (details.isEmpty || trackballBehavior.builder == null) {
      _trackballBuilder = const SizedBox(width: 0, height: 0);
    } else if (details.isNotEmpty &&
        trackballBehavior.builder != null &&
        chartPointInfo.isNotEmpty) {
      _trackballBuilder = Stack(
        children: List<Widget>.generate(details.length, (int index) {
          final ChartPointInfo info = chartPointInfo[index];
          final Widget builder =
              trackballBehavior.builder!.call(context, details[index]);
          return TrackballBuilderRenderObjectWidget(
            index: index,
            xPos: info.xPosition!,
            yPos: info.yPosition!,
            builder: builder,
            chartPointInfo: chartPointInfo,
            trackballBehavior: trackballBehavior,
            child: builder,
          );
        }).toList(),
      );
    }
    final RenderObjectElement? trackballBuilderElement =
        _trackballBuilderKey.currentContext as RenderObjectElement?;
    if (trackballBuilderElement != null &&
        trackballBuilderElement.mounted &&
        trackballBuilderElement.renderObject.attached) {
      final RenderObject? renderObject =
          trackballBuilderElement.findRenderObject();
      if (renderObject != null &&
          renderObject.attached &&
          renderObject is RenderConstrainedLayoutBuilder) {
        renderObject.markNeedsBuild();
      }
    }
  }

inside /Users/me/.pub-cache/hosted/pub.dev/syncfusion_flutter_charts-26.2.11/lib/src/charts/cartesian_chart.dart

Screenshots or Video

Screenshots / Video demonstration Screenshot 2024-08-30 at 00 18 33

Screenshot 2024-08-29 at 23 59 16

Stack Traces

Stack Traces
Error (Xcode): ../../../.pub-cache/hosted/pub.dev/syncfusion_flutter_charts-26.2.11/lib/src/charts/cartesian_chart.dart:1367:22: Error: The method 'markNeedsBuild' isn't defined for the class 'RenderConstrainedLayoutBuilder<Constraints, RenderObject>'.

Could not build the application for the simulator.
Error launching application on iPhone 11 Pro.

On which target platforms have you observed this bug?

iOS

Flutter Doctor output

Doctor output
[✓] Flutter (Channel stable, 3.24.1, on macOS 14.6.1 23G93 darwin-arm64, locale en-US)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 15.3)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2023.3)
[✓] IntelliJ IDEA Ultimate Edition (version 2024.2.0.2)
[✓] VS Code (version 1.89.0)
[✓] Connected device (4 available)
[✓] Network resources

• No issues found!
@nguyenxdat
Copy link

Same here

@WCCSMobile23
Copy link

when i upgrade flutter then this issue in my project

@PreethikaSelvam
Copy link
Contributor

Hi All,

The reported issue arises because the Flutter SDK was upgraded to version 3.24.0 on August 6, 2024, while our packages are currently compatible with Flutter SDK version 3.22.3. We almost completed evaluating the compatibility and feasibility of updating our packages to work with the latest Flutter version, 3.24.0. We plan to make our packages compatible and include them in our Volume 3 main release, which is expected to be rolled out in the second week of September. In the meantime, we kindly request that you use Flutter SDK version 3.22.3 when working with our syncfusion_flutter_charts package.

Regards,
Preethika Selvam.

@VijayakumarMariappan VijayakumarMariappan added charts Charts component follow-up scheduled Follow-up scheduled labels Sep 2, 2024
@umairali435
Copy link

is there any solution without downgrading flutter ?

@alarkirikal
Copy link

I'm sorry, but that reply is disappointing. If all 3rd party packages would take the stance of forcing older Flutter levels instead of keeping up with the ecosystem, it'd be a chaos. It should be one of your core efforts to have support for official releases of Flutter.

@jeanlucthumm
Copy link

Fastest way to deal with this:

Install https://fvm.app/

Then run

fvm use 3.22.3
fvm flutter run

@withden
Copy link

withden commented Sep 10, 2024

I think they updated (Now it's compatible with Flutter 3.24): https://pub.dev/packages/syncfusion_flutter_charts/changelog

@MrSuradechTH
Copy link

latest version can run as normally

@ThilipChandru
Copy link
Collaborator

ThilipChandru commented Sep 11, 2024

Hi All,

Thank you for your patience. We have upgraded our Flutter Charts package to be compatible with Flutter SDK 3.24.0. We kindly request you to upgrade Flutter Charts to the latest version.

Charts: https://pub.dev/packages/syncfusion_flutter_charts/versions/26.2.14

Regards,
Thilip Chandru.

@LavanyaGowtham2021 LavanyaGowtham2021 added waiting for customer response Cannot make further progress until the customer responds. and removed follow-up scheduled Follow-up scheduled labels Sep 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
charts Charts component waiting for customer response Cannot make further progress until the customer responds.
Projects
None yet
Development

No branches or pull requests