You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

使用gimdongwoo.ti-media-picker-widget遇x86_64架构模块找不到错误求助

Fixing the "Couldn't find module: ti.mediapicker for architecture: x86_64" Error with the ti-media-picker Widget

Hey there, let’s work through this module not found error together—this is a common gotcha with Appcelerator widgets, and we can break down the fixes step by step:

1. Double-Check Widget Installation & Reference

First, make sure you’re referencing the widget correctly, not the raw module:

  • Verify the widget is placed in your project’s app/widgets/gimdongwoo.ti-media-picker-widget directory (no typos in the folder name!).
  • Confirm your config.json includes the widget dependency:
    "dependencies": {
        "gimdongwoo.ti-media-picker-widget": "1.0.0" // Use the actual version from the widget docs
    }
    
  • Critical: Don’t use require('ti.mediapicker') directly. Instead, instantiate the widget as per its docs:
    const mediaPicker = Alloy.createWidget('gimdongwoo.ti-media-picker-widget', 'widget', {
        // Add your config options here
    });
    mediaPicker.openPicker();
    

2. Fix Architecture Support for iOS Simulator

The x86_64 error means the widget’s precompiled module doesn’t support the iOS simulator architecture. Try these:

  • Test on a physical iOS device: Arm64 architecture (used by real iPhones/iPads) is likely supported, so this might bypass the issue immediately.
  • Recompile the module for x86_64:
    1. Grab the widget’s source code from its repo.
    2. Open the module’s Xcode project (usually in modules/iphone/ti.mediapicker/).
    3. Set the build architecture to include both x86_64 and arm64, then recompile.
    4. Replace the old module files in your project with the newly compiled ones.

3. Clear Appcelerator Cache

Appcelerator’s build cache often causes module detection issues:

  • Delete the build/ folder in your project root.
  • Run appc clean in your terminal (if you have the Appcelerator CLI installed).
  • Restart your Appcelerator Studio or CLI, then rebuild the project.

4. Verify SDK Compatibility

Check the widget’s documentation for supported Appcelerator SDK versions. If you’re using a newer SDK, try downgrading to the version recommended by the widget—older widgets sometimes break with latest SDK updates.

内容的提问来源于stack exchange,提问作者user3752705

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.26 08:54:58