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

[bug]: build runner failing on Stacked-generator-1.6.1-pre.1 #1100

Open
johnsonejezie opened this issue Apr 22, 2024 · 3 comments
Open

[bug]: build runner failing on Stacked-generator-1.6.1-pre.1 #1100

johnsonejezie opened this issue Apr 22, 2024 · 3 comments

Comments

@johnsonejezie
Copy link

Describe the bug

Built build_runner:build_runner.
[INFO] Generating build script completed, took 752ms
[WARNING] ../../.pub-cache/hosted/pub.dev/stacked_generator-1.6.1-pre.1/lib/src/generators/getit/dependency_config_factory.dart:119:51: Error: Undefined name 'InitializableSingleton'.
.instanceOf(const TypeChecker.fromRuntime(InitializableSingleton))) {
^^^^^^^^^^^^^^^^^^^^^^
[INFO] Precompiling build script... completed, took 1.6s
[SEVERE] Failed to precompile build script .dart_tool/build/entrypoint/build.dart.
This is likely caused by a misconfigured builder definition.

What operating system do you use?

macOS

Information about the installed tooling

No response

Steps to reproduce the issue

Run dart run build_runner build --delete-conflicting-outputs
stacked: 3.4.2
stacked_services: 1.5.0
stacked_generator: 1.6.1-pre.1

Expected behavior

No response

Screenshots

No response

Additional Context

No response

@FilledStacks
Copy link
Contributor

@johnsonejezie could you do stacked create app pre_test then update the generator to the latest and see if it does the same.

@bhagn
Copy link

bhagn commented Jun 11, 2024

@FilledStacks I'm having the same issue. I'm not using the CLI. I was upgrading from 3.2.6 to 3.4.2 and stacked_generator from 1.3.3.

I have tried both 1.5.2 and 1.6.0 - both give the same error:

$ flutter pub run build_runner watch --delete-conflicting-outputs
Deprecated. Use `dart run` instead.
[INFO] Generating build script completed, took 169ms
[WARNING] ../../.pub-cache/hosted/pub.dev/stacked_generator-1.5.2/lib/src/generators/getit/dependency_config_factory.dart:119:51: Error: Undefined name 'InitializableSingleton'.
        .instanceOf(const TypeChecker.fromRuntime(InitializableSingleton))) {
                                                  ^^^^^^^^^^^^^^^^^^^^^^
[INFO] Precompiling build script... completed, took 3.7s
[SEVERE] Failed to precompile build script .dart_tool/build/entrypoint/build.dart.
This is likely caused by a misconfigured builder definition.
$ flutter pub run build_runner watch --delete-conflicting-outputs
Deprecated. Use `dart run` instead.
[INFO] Generating build script completed, took 183ms
[WARNING] ../../.pub-cache/hosted/pub.dev/stacked_generator-1.6.0/lib/src/generators/getit/dependency_config_factory.dart:119:51: Error: Undefined name 'InitializableSingleton'.
        .instanceOf(const TypeChecker.fromRuntime(InitializableSingleton))) {
                                                  ^^^^^^^^^^^^^^^^^^^^^^
[INFO] Precompiling build script... completed, took 620ms
[SEVERE] Failed to precompile build script .dart_tool/build/entrypoint/build.dart.
This is likely caused by a misconfigured builder definition.

@FilledStacks
Copy link
Contributor

That usually means the type is not there from the stacked_shared package.

Could you give us a reproducible example please, that would help in us fixing it because we can't reproduce on our side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants