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

build error in flutter 1.10.15, ExtendedMemoryImageProvider.load' has fewer positional arguments than those of overridden method 'MemoryImage.load'. #80

Closed
mana-ai opened this issue Oct 21, 2019 · 25 comments

Comments

@mana-ai
Copy link

mana-ai commented Oct 21, 2019

pub.flutter-io.cn/extended_image_library-0.1.8/lib/src/extended_me
mory_image_provider.dart:12:24: Error: The method 'ExtendedMemoryImageProvider.load' has fewer positional arguments
than those of overridden method 'MemoryImage.load'.
ImageStreamCompleter load(MemoryImage key) {

@zmtzawqlp zmtzawqlp added the bug Something isn't working label Oct 22, 2019
@zmtzawqlp
Copy link
Member

zmtzawqlp commented Oct 22, 2019

please use previous-version for now, i will fix it as soon as possible

@zmtzawqlp
Copy link
Member

please provide version of flutter sdk , i didn't see any problem from my side

@Codered81
Copy link

Cached_network_image package has the exact same issue, they provided an RC as a temporary fix due to the breaking change in Flutter SDK.

@zmtzawqlp
Copy link
Member

zmtzawqlp commented Oct 22, 2019

ok, thanks, I see,i will fix it in dev branch as soon as possible. you can use it as git url

@zmtzawqlp zmtzawqlp pinned this issue Oct 22, 2019
@zmtzawqlp zmtzawqlp changed the title pub.flutter-io.cn/extended_image_library-0.1.8/lib/src/extended_me mory_image_provider.dart:12:24: Error: The method 'ExtendedMemoryImageProvider.load' has fewer positional arguments than those of overridden method 'MemoryImage.load'. ImageStreamCompleter load(MemoryImage key) { build error in flutter 1.10.15, ExtendedMemoryImageProvider.load' has fewer positional arguments than those of overridden method 'MemoryImage.load'. Oct 22, 2019
@zmtzawqlp
Copy link
Member

please add following code to your pubspec.yaml for now. i have fixed build error in dev branch, i will publish it to pub.com when 1.10.15 is in stable branch

dependency_overrides:
  extended_image_library:
    git:
        url: https://github.com/fluttercandies/extended_image_library.git
        ref: dev

@ThinkDigitalSoftware
Copy link

please add following code to your pubspec.yaml for now. i have fixed build error in dev branch, i will publish it to pub.com when 1.10.15 is in stable branch

dependency_overrides:
  extended_image_library:
    git:
        url: https://github.com/fluttercandies/extended_image_library.git
        ref: dev

Weird, when I get it from git like you mentioned, it pulls version 0.1.9 even though that's not what it says on that branch...

@zmtzawqlp
Copy link
Member

@ThinkDigitalSoftware extended_image_library is 0.1.9 on dev branch

@hmilitar
Copy link

Hi my results after i did flutter pub get:

! extended_image_library 0.1.9 from git https://github.com/fluttercandies/extended_image_library.git at c00560

@hmilitar
Copy link

Is this issue resolved already? kindly post solution please... tried above...still getting same error as the title of the issue. Thanks!

@zmtzawqlp
Copy link
Member

zmtzawqlp commented Nov 15, 2019

@hmilitar it's right. i will publish it to pub.com when 1.10.15 is in stable branch

dependency_overrides:
extended_image_library:
git:
url: https://github.com/fluttercandies/extended_image_library.git
ref: dev

@bambinoua
Copy link

bambinoua commented Dec 2, 2019

@hmilitar it's right. i will publish it to pub.com when 1.10.15 is in stable branch

dependency_overrides:
extended_image_library:
git:
url: https://github.com/fluttercandies/extended_image_library.git
ref: dev

Unfortunately this does not help! Still have the same crash. Flutter is 1.11.0. So how to fix this?

@zmtzawqlp
Copy link
Member

double check your extended_image_library version , it should be 0.1.9 at your side.

@bambinoua
Copy link

bambinoua commented Dec 2, 2019

double check your extended_image_library version , it should be 0.1.9 at your side.

pubspec.lock shows 1.0.8. I commented extended_image and extended_image_library in pubspec.yaml to remove them from lock-file (maybe some caching) then I add them again. Version is 1.0.8.

P.S. By the way I don't see 1.0.9 version on git. Only this ## [0.1.8]

@zmtzawqlp
Copy link
Member

do you add following ??

image

@bambinoua
Copy link

bambinoua commented Dec 2, 2019

do you add following ??

I am sorry my mistake. I wrote rev instead of ref. Now looks good. Thanks!

@OPY-bbt
Copy link

OPY-bbt commented Dec 10, 2019

fixed?

@zmtzawqlp
Copy link
Member

fixed version is on pub

@zmtzawqlp zmtzawqlp unpinned this issue Dec 11, 2019
@masashi-sutou
Copy link

masashi-sutou commented Dec 11, 2019

@zmtzawqlp
I use Flutter (Channel stable, v1.9.1+hotfix.6, on Linux, locale C.UTF-8).

I have same error in extend_image 0.6.8 and extend_image_library 0.1.9.

Although the argument type is specified, I don't think DecoderCallback is defined anywhere.

What is DecoderCallback?

@zmtzawqlp
Copy link
Member

double check your local version .remove lock and packages , run flutter packages get .@masashi-sutou

@masashi-sutou
Copy link

masashi-sutou commented Dec 11, 2019

@zmtzawqlp Thank you for your reply.

I try remove pubspec.lock and run flutter packages get, but have same error.

error get packeages

Sorry if wrong, type should be ImageDecoderCallback, not DecoderCallback.

for now, I take the workaround.

dependencies:
  extended_image: 0.6.7

# version 0.1.8 commit hash
dependency_overrides:
  extended_image_library:
    git:
      url: https://github.com/fluttercandies/extended_image_library.git
      ref: b08fdf4e99a09967d0e44dbebac5d1584270205c

@zmtzawqlp
Copy link
Member

extended_image: 0.6.8 include extended_image_library 0.1.9 , it's fixed the build error

@zmtzawqlp
Copy link
Member

and I use Flutter (Channel stable, v1.9.1+hotfix.6, on Linux, locale C.UTF-8).

you should not use lastest version of extended image, see more #89

@qq329401134
Copy link

/D:/Program%20Files/Flutter/.pub-cache/hosted/pub.flutter-io.cn/extended_image_library-0.1.9/lib/src/extended_asset_bundle_image_provider.dart:88:54: Error: 'DecoderCallback' isn't a type.
ImageStreamCompleter load(AssetBundleImageKey key, DecoderCallback decode) {

我的这样提示 使用的flutter是1.9.1 hotfix.6 咋办

@zmtzawqlp
Copy link
Member

/D:/Program%20Files/Flutter/.pub-cache/hosted/pub.flutter-io.cn/extended_image_library-0.1.9/lib/src/extended_asset_bundle_image_provider.dart:88:54: Error: 'DecoderCallback' isn't a type.
ImageStreamCompleter load(AssetBundleImageKey key, DecoderCallback decode) {

我的这样提示 使用的flutter是1.9.1 hotfix.6 咋办

#89

@masashi-sutou
Copy link

@zmtzawqlp

Thank you for maintaining this package.
Using the latest stable channel 1.12.13 + hotfix .5, the latest extended_image 0.6.8 and extended_image_library 0.1.9 were successfully built.

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

No branches or pull requests

9 participants