无法在颤振中执行 Syncfusion 仪表图表

Unable to execute Syncfusion gauge chart in flutter

无法在 flutter 中执行 Syncfusion 仪表图,我已经根据 pub.dev 中的文档导入了 syncfusion,在 运行 出现错误后,我的 pubspec.yaml 文件也

我得到的错误是 '

失败:构建失败,出现异常。

Process 'command '/Users/apple/flutter/bin/flutter'' finished with non-zero exit value 1

15 秒内构建失败 异常:Gradle 任务 assembleDebug 失败,退出代码为 1 '

'''

import 'package:flutter/material.dart'; 
import 'package:syncfusion_flutter_gauges/gauges.dart'; 
void main(){
  runApp(new MaterialApp( 
  home:new myapp() ,
 ));
 }
 class myapp extends StatefulWidget {
  const myapp({Key? key}) : super(key: key);

 @override
  _myappState createState() => _myappState(); 
 }
  class _myappState extends State<myapp> {    
   @override
   Widget build(BuildContext context) {
    return new Scaffold(
      appBar: new AppBar(
   title: new Text("MyApp"),
   ),
    body:Container(
        child:Container(
          height: 500,
          width: 500,
            child: SfRadialGauge(
                axes: <RadialAxis>[
                  RadialAxis(minimum: 0, maximum: 150,
                      ranges: <GaugeRange>[
                        GaugeRange(startValue: 0, endValue: 50, color:Colors.green),
                        GaugeRange(startValue: 50,endValue: 100,color: Colors.orange),
                        GaugeRange(startValue: 100,endValue: 150,color: Colors.red)],
                      pointers: <GaugePointer>[
                        NeedlePointer(value: 90)],
                      annotations: <GaugeAnnotation>[
                        GaugeAnnotation(widget: Container(child:
                        Text('90.0',style: TextStyle(fontSize: 25,fontWeight: FontWeight.bold))),
                            angle: 90, positionFactor: 0.5
                        )]
                  )]),
        ),
    )
);
}
}

'''

我已经检查了上述情况,无法从我这边重现上述问题。我建议你 运行 flutter clean 命令再试一次。如果您仍然遇到这个问题,请分享一个简单的示例项目来重现您遇到的问题。