I dunno if this is your issue, but...
Your library is in dependencies in build_runner and after last updating 2.2.0 --> 2.3.0 an issue was happened.
When there are both annotations in class, like that,
part 'user.freezed.dart' ;
part 'user.g.dart' ;
/// Класс пользователя для авторизации
@freezed
class AuthUser with _$AuthUser {
/// Базовый класс typeId: 0, adapterName: 'AuthUserAdapter'
@HiveType (typeId: 0 )
const factory AuthUser ({
@HiveField (0 ) required String id,
}) = _AuthUser ;
/// AuthUser.fromJson
factory AuthUser .fromJson (Map <String , dynamic > json) =>
_$AuthUserFromJson (json);
json_annotation which is indirectly called from freezed had been adding its annotations in ".g.dart" alongside with hive
part of 'user.dart' ;
// **************************************************************************
// TypeAdapterGenerator
// **************************************************************************
class AuthUserAdapter extends TypeAdapter <_$_AuthUser > {
@override
final int typeId = 0 ;
// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************
_$_AuthUser _$$_AuthUserFromJson (Map <String , dynamic > json) => $checkedCreate (
r'_$_AuthUser' ,
json,
($checkedConvert) {
final val = _$_AuthUser (
As a result of last night updating of graphs json generator overrides file .g.dart and previous info disappears.
I added this issue to build_runner repository too.
👍 React with 👍 12KabaDH, sk784, mozerrr, spioc999, mocki-toki and 7 more