flutter / flutter

Flutter makes it easy and fast to build beautiful apps for mobile and beyond
https://flutter.dev
BSD 3-Clause "New" or "Revised" License
163.6k stars 26.91k forks source link

As requested,, I'm reporting a "we should provide substanittailly more information" exception #150414

Closed richardhaven closed 1 week ago

richardhaven commented 1 month ago

Steps to reproduce

Buildiing conditional Widget lists

Expected results

paint my widgets on the screen

Actual results

======== Exception caught by rendering library =====================================================
The following assertion was thrown during paint():
RenderBox was not laid out: _RenderLayoutBuilder#c47d3 relayoutBoundary=up16 NEEDS-PAINT
'package:flutter/src/rendering/box.dart':
Failed assertion: line 2165 pos 12: 'hasSize'

Either the assertion indicates an error in the framework itself, or we should provide substantially more information in this error message to help you determine and fix the underlying cause.
In either case, please report this assertion by filing a bug on GitHub:
  https://github.com/flutter/flutter/issues/new?template=2_bug.yml

The relevant error-causing widget was: 
  SingleChildScrollView SingleChildScrollView:file:///C:/Users/richard/Projects/save_our_places/lib/screens/screen_wrapper.dart:27:16
When the exception was thrown, this was the stack: 
#2      RenderBox.size (package:flutter/src/rendering/box.dart:2165:12)
#3      _RenderSingleChildViewport._shouldClipAtPaintOffset (package:flutter/src/widgets/single_child_scroll_view.dart:513:40)
#4      _RenderSingleChildViewport.paint (package:flutter/src/widgets/single_child_scroll_view.dart:527:11)
#5      RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#6      PaintingContext._repaintCompositedChild (package:flutter/src/rendering/object.dart:166:11)
#7      PaintingContext.repaintCompositedChild (package:flutter/src/rendering/object.dart:109:5)
#8      PaintingContext._compositeChild (package:flutter/src/rendering/object.dart:261:7)
#9      PaintingContext.paintChild (package:flutter/src/rendering/object.dart:242:7)
#10     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#11     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#12     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#13     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#14     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#15     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#16     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#17     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#18     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#19     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#20     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#21     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#22     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#23     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#24     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#25     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#26     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#27     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#28     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#29     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#30     PaintingContext._repaintCompositedChild (package:flutter/src/rendering/object.dart:166:11)
#31     PaintingContext.repaintCompositedChild (package:flutter/src/rendering/object.dart:109:5)
#32     PaintingContext._compositeChild (package:flutter/src/rendering/object.dart:261:7)
#33     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:242:7)
#34     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#35     RenderCustomPaint.paint (package:flutter/src/rendering/custom_paint.dart:633:11)
#36     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#37     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#38     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#39     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#40     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#41     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#42     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#43     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#44     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#45     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#46     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#47     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#48     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#49     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#50     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#51     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#52     PaintingContext._repaintCompositedChild (package:flutter/src/rendering/object.dart:166:11)
#53     PaintingContext.repaintCompositedChild (package:flutter/src/rendering/object.dart:109:5)
#54     PaintingContext._compositeChild (package:flutter/src/rendering/object.dart:261:7)
#55     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:242:7)
#56     RenderShiftedBox.paint (package:flutter/src/rendering/shifted_box.dart:74:15)
#57     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#58     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#59     RenderBoxContainerDefaultsMixin.defaultPaint (package:flutter/src/rendering/box.dart:3158:15)
#60     RenderCustomMultiChildLayoutBox.paint (package:flutter/src/rendering/custom_layout.dart:409:5)
#61     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#62     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#63     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#64     _RenderInkFeatures.paint (package:flutter/src/material/material.dart:662:11)
#65     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#66     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#67     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#68     RenderPhysicalModel.paint.<anonymous closure> (package:flutter/src/rendering/proxy_box.dart:2033:15)
#69     PaintingContext.pushClipRRect (package:flutter/src/rendering/object.dart:575:14)
#70     RenderPhysicalModel.paint (package:flutter/src/rendering/proxy_box.dart:2020:21)
#71     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#72     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#73     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#74     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#75     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#76     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#77     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#78     PaintingContext._repaintCompositedChild (package:flutter/src/rendering/object.dart:166:11)
#79     PaintingContext.repaintCompositedChild (package:flutter/src/rendering/object.dart:109:5)
#80     PaintingContext._compositeChild (package:flutter/src/rendering/object.dart:261:7)
#81     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:242:7)
#82     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#83     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#84     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#85     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#86     _ZoomExitTransitionPainter.paint (package:flutter/src/material/page_transitions_theme.dart:1068:23)
#87     _RenderSnapshotWidget.paint (package:flutter/src/widgets/snapshot_widget.dart:337:15)
#88     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#89     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#90     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#91     _RenderSnapshotWidget._paintAndDetachToImage (package:flutter/src/widgets/snapshot_widget.dart:303:11)
#92     _RenderSnapshotWidget.paint (package:flutter/src/widgets/snapshot_widget.dart:347:22)
#93     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#94     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#95     RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#96     _ZoomExitTransitionPainter.paint (package:flutter/src/material/page_transitions_theme.dart:1068:23)
#97     _RenderSnapshotWidget.paint (package:flutter/src/widgets/snapshot_widget.dart:337:15)
#98     RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#99     PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#100    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#101    _ZoomEnterTransitionPainter.paint (package:flutter/src/material/page_transitions_theme.dart:996:23)
#102    _RenderSnapshotWidget.paint (package:flutter/src/widgets/snapshot_widget.dart:337:15)
#103    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#104    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#105    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#106    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#107    PaintingContext._repaintCompositedChild (package:flutter/src/rendering/object.dart:166:11)
#108    PaintingContext.repaintCompositedChild (package:flutter/src/rendering/object.dart:109:5)
#109    PaintingContext._compositeChild (package:flutter/src/rendering/object.dart:261:7)
#110    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:242:7)
#111    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#112    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#113    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#114    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#115    RenderOffstage.paint (package:flutter/src/rendering/proxy_box.dart:3732:11)
#116    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#117    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#118    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#119    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#120    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#121    _RenderTheaterMixin.paint (package:flutter/src/widgets/overlay.dart:1001:15)
#122    PaintingContext.pushLayer (package:flutter/src/rendering/object.dart:486:12)
#123    PaintingContext.pushClipRect (package:flutter/src/rendering/object.dart:546:7)
#124    _RenderTheater.paint (package:flutter/src/widgets/overlay.dart:1322:38)
#125    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#126    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#127    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#128    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#129    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#130    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#131    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#132    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#133    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#134    RenderCustomPaint.paint (package:flutter/src/rendering/custom_paint.dart:633:11)
#135    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#136    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#137    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#138    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#139    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#140    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#141    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#142    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#143    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#144    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#145    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#146    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#147    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#148    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#149    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#150    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#151    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#152    RenderProxyBoxMixin.paint (package:flutter/src/rendering/proxy_box.dart:130:13)
#153    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#154    PaintingContext.paintChild (package:flutter/src/rendering/object.dart:250:13)
#155    RenderView.paint (package:flutter/src/rendering/view.dart:275:15)
#156    RenderObject._paintWithContext (package:flutter/src/rendering/object.dart:3239:7)
#157    PaintingContext._repaintCompositedChild (package:flutter/src/rendering/object.dart:166:11)
#158    PaintingContext.repaintCompositedChild (package:flutter/src/rendering/object.dart:109:5)
#159    PipelineOwner.flushPaint (package:flutter/src/rendering/object.dart:1182:31)
#160    PipelineOwner.flushPaint (package:flutter/src/rendering/object.dart:1192:15)
#161    RendererBinding.drawFrame (package:flutter/src/rendering/binding.dart:579:23)
#162    WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:1138:13)
#163    RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:443:5)
#164    SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1392:15)
#165    SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1313:9)
#166    SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:1171:5)
#167    _invoke (dart:ui/hooks.dart:312:13)
#168    PlatformDispatcher._drawFrame (dart:ui/platform_dispatcher.dart:419:5)
#169    _drawFrame (dart:ui/hooks.dart:283:31)
(elided 2 frames from class _AssertionError)
The following RenderObject was being processed when the exception was fired: _RenderSingleChildViewport#2954b relayoutBoundary=up15
...  needs compositing
...  parentData: <none> (can use size)
...  constraints: BoxConstraints(0.0<=w<=1217.3, 0.0<=h<=578.7)
...  layer: OffsetLayer#3c1be DETACHED
...    engine layer: OffsetEngineLayer#2df9d
...    handles: 1
...    offset: Offset(0.0, 0.0)
...  size: Size(1217.3, 32.0)
...  offset: Offset(0.0, -0.0)
RenderObject: _RenderSingleChildViewport#2954b relayoutBoundary=up15
  needs compositing
  parentData: <none> (can use size)
  constraints: BoxConstraints(0.0<=w<=1217.3, 0.0<=h<=578.7)
  layer: OffsetLayer#3c1be DETACHED
    engine layer: OffsetEngineLayer#2df9d
    handles: 1
    offset: Offset(0.0, 0.0)
  size: Size(1217.3, 32.0)
  offset: Offset(0.0, -0.0)
...  child: _RenderLayoutBuilder#c47d3 relayoutBoundary=up16 NEEDS-PAINT
...    parentData: <none> (can use size)
...    constraints: BoxConstraints(0.0<=w<=1217.3, 0.0<=h<=Infinity)
...    size: MISSING
...    child: RenderFlex#9e55f relayoutBoundary=up17 NEEDS-PAINT
...      parentData: offset=Offset(0.0, 0.0) (can use size)
...      constraints: BoxConstraints(0.0<=w<=1217.3, 0.0<=h<=Infinity)
...      size: MISSING
...      direction: vertical
...      mainAxisAlignment: start
...      mainAxisSize: max
...      crossAxisAlignment: start
...      textDirection: ltr
...      verticalDirection: down
...      child 1: RenderFlex#8f264 NEEDS-LAYOUT NEEDS-PAINT
...        parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...        constraints: MISSING
...        size: MISSING
...        direction: horizontal
...        mainAxisAlignment: start
...        mainAxisSize: max
...        crossAxisAlignment: center
...        textDirection: ltr
...        verticalDirection: down
...        child 1: RenderParagraph#ffa1e NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          textAlign: start
...          textDirection: ltr
...          softWrap: wrapping at box width
...          overflow: clip
...          locale: en_US
...          maxLines: unlimited
...        child 2: RenderConstrainedBox#413c9 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          additionalConstraints: BoxConstraints(w=10.0, 0.0<=h<=Infinity)
...        child 3: RenderParagraph#1376d NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          textAlign: start
...          textDirection: ltr
...          softWrap: wrapping at box width
...          overflow: clip
...          locale: en_US
...          maxLines: unlimited
...        child 4: RenderConstrainedBox#ec160 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          additionalConstraints: BoxConstraints(w=20.0, 0.0<=h<=Infinity)
...        child 5: RenderSemanticsAnnotations#ad3db NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          semantic boundary
...          size: MISSING
...        child 6: RenderConstrainedBox#8a434 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          additionalConstraints: BoxConstraints(w=20.0, 0.0<=h<=Infinity)
...        child 7: RenderSemanticsAnnotations#926a1 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          semantic boundary
...          size: MISSING
...      child 2: RenderFlex#5a3a8 NEEDS-LAYOUT NEEDS-PAINT
...        parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...        constraints: MISSING
...        size: MISSING
...        direction: horizontal
...        mainAxisAlignment: start
...        mainAxisSize: max
...        crossAxisAlignment: center
...        textDirection: ltr
...        verticalDirection: down
...        child 1: RenderConstrainedBox#884b0 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          additionalConstraints: BoxConstraints(w=30.0, 0.0<=h<=Infinity)
...        child 2: RenderParagraph#3a483 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          textAlign: start
...          textDirection: ltr
...          softWrap: wrapping at box width
...          overflow: clip
...          locale: en_US
...          maxLines: unlimited
...        child 3: RenderConstrainedBox#f2fba NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          additionalConstraints: BoxConstraints(w=10.0, 0.0<=h<=Infinity)
...        child 4: RenderParagraph#fc32b NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          textAlign: start
...          textDirection: ltr
...          softWrap: wrapping at box width
...          overflow: clip
...          locale: en_US
...          maxLines: unlimited
...        child 5: RenderConstrainedBox#511ef NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...          additionalConstraints: BoxConstraints(w=0.0, h=0.0)
...      child 3: RenderFlex#f4816 NEEDS-LAYOUT NEEDS-PAINT
...        parentData: offset=Offset(0.0, 0.0); flex=1; fit=FlexFit.tight
...        constraints: MISSING
...        size: MISSING
...        direction: vertical
...        mainAxisAlignment: start
...        mainAxisSize: max
...        crossAxisAlignment: center
...        verticalDirection: up
...        child 1: RenderErrorBox#ecdd4 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=null; fit=null
...          constraints: MISSING
...          size: MISSING
...        child 2: _RenderLayoutBuilder#af989 NEEDS-LAYOUT NEEDS-PAINT
...          parentData: offset=Offset(0.0, 0.0); flex=1; fit=FlexFit.tight
...          constraints: MISSING
...          size: MISSING
====================================================================================================

Code sample

Code sample ```dart Row buildAccountRow(Accounts possibleAccounts, BuildContext context) { List accountWidgets = [const Text('Account:'), const SizedBox(width: 10)]; if (possibleAccounts.length == 0) { appState.currentQueue = null; accountWidgets.add(const Text('No accounts!')); } else if (possibleAccounts.length == 1) { // all non-superusers appState.currentAccount = possibleAccounts[0]; accountWidgets.add(Text(appState.currentAccount!.name!)); } else { Widget anAccountPicker = AccountPicker( accounts: possibleAccounts, selected: possibleAccounts[0], onAccountChange: (Account? selectedAccount) { this.setState(() { appState.currentAccount = selectedAccount; if (selectedAccount != null && selectedAccount.queues.length > 0) { appState.currentQueue = selectedAccount.queues[0]; } }); }); accountWidgets.add(anAccountPicker); } if (appState.userHasRight(UserRight.modifyOwnAccount) && appState.currentAccount != null) { accountWidgets.add(const SizedBox(width: 20)); accountWidgets.add( ElevatedButton( onPressed: () async { Account editableAccount = appState.currentAccount!.copy; bool? response = await context.push("/account", extra: editableAccount); if (response == true) { editableAccount.overwrite(appState.currentAccount!); } }, child: Text('Edit Account'.i18n), ), ); } if (appState.userHasRight(UserRight.createAccount)) { accountWidgets.add(const SizedBox(width: 20)); accountWidgets.add(ElevatedButton( onPressed: () async { Account newAccount = Account(); bool? response = await context.push("/account", extra: newAccount); if (response == true) { appState.data.accounts.add(newAccount); } }, child: Text('Create an Account'.i18n), )); } return Row(mainAxisAlignment: MainAxisAlignment.start, children: accountWidgets); } ```

Screenshots or Video

Screenshots / Video demonstration [Upload media here]

Logs

Logs ```console [Paste your logs here] ```

Flutter Doctor output

Doctor output ```console PS C:\Users\richard\Projects\save_our_places> flutter doctor Doctor summary (to see all details, run flutter doctor -v): [√] Flutter (Channel stable, 3.22.2, on Microsoft Windows [Version 10.0.22631.3737], locale en-US) [√] Windows Version (Installed version of Windows is version 10 or higher) [√] Android toolchain - develop for Android devices (Android SDK version 34.0.0) [√] Chrome - develop for the web [√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.10.2) [√] Android Studio (version 2023.3) [√] Connected device (3 available) [√] Network resources • No issues found! ```
danagbemava-nc commented 1 month ago

Hi @richardhaven, the code sample you provided above is lacking in context so we cannot offer much help here. If you are using a Row in SingleChildScrollView, you should probably wrap it in an object that constraints the size of the Row, like a SizedBox or a ConstrainedBox.

Please provide a complete runnable minimal reproducible code sample so that we can properly investigate this.

Thank you

github-actions[bot] commented 1 week ago

Without additional information, we are unfortunately not sure how to resolve this issue. We are therefore reluctantly going to close this bug for now. If you find this problem please file a new issue with the same description, what happens, logs and the output of 'flutter doctor -v'. All system setups can be slightly different so it's always better to open new issues and reference the related ones. Thanks for your contribution.