0

I am facing the problem while making the build of the app. Some files are autogenerated and during that some of the import paths are written wrong:

In update_attendance.ast.gql.dart

// GENERATED CODE - DO NOT MODIFY BY HAND

import 'package:firm_mobile%5Csrc%5Cnetwork%5Cgraphql%5Coperations%5Cevents%5Cupdate_attendance%5C__generated__%5Cupdate_attendance.ast.gql.dart'
    as _i2;
import 'package:gql/ast.dart' as _i1;

Error:

[SEVERE] ferry_generator:graphql_builder on lib/src/network/graphql/operations/events/update_attendance/update_attendance.graphql:

Could not format because the source could not be parsed:

line 1, column 213 of .: An escape sequence starting with '\u' must be followed by 4 hexadecimal digits.
  ╷
1 │ import 'package:firm_mobile\src\network\graphql\operations\events\update_attendance\__generated__\update_attendance.ast.gql.dart' as _i5;import 'package:firm_mobile\src\network\graphql\operations\events\update_attendance\__
generated__\update_attendance.data.gql.dart' as _i2;import 'package:firm_mobile\src\network\graphql\operations\events\update_attendance\__generated__\update_attendance.var.gql.dart' as _i3;import 'package:firm_mobile/src/networ
k/graphql/schema/__generated__/serializers.gql.dart' as _i6;import 'package:built_value/built_value.dart';import 'package:built_value/serializer.dart';import 'package:ferry_exec/ferry_exec.dart' as _i1;import 'package:gql_exec/gql_exec.d
art' as _i4;
  │                                                                                                                                                                                                                     ^^
  ╵

Where in the settings of Android Studio I can check or change how the / has to be interpreted (format settings)?

I am using Windows. On Mac this problem doesn't appear. But I need to solve it on Windows.

  • i had set the global and project encoding to UTF-8, but still get same mistake. [Source] (https://stackoverflow.com/questions/30078805/which-encoding-should-i-use-for-my-android-studio-project) – macarinatalia May 30 '22 at 12:58

1 Answers1

0

Apparently, it is the problem of the package ferry_generator on Windows' machines. It is still an open issue, but there are some possible solutions.

Check this discussion.

Downgrade was not an option for me, so i set in the pubspec.yaml the github link to the ferry_generator.

It is working by now, no one knows how it will be in near future. Hope, that the issue will be solved soon.