Results 1 to 7 of 7

Thread: Sencha package build problem

  1. #1
    Sencha Premium Member
    Join Date
    Mar 2016
    Location
    austin, TX
    Posts
    3

    Default Sencha package build problem

    Hi,

    I am trying to setup and build a local package and am having problems. I have searched the forums/Google and while finding others with the problem I haven't been able to resolve the problem.

    I followed the instructions on Cmd Guides -> Sencha Cmd Packages.
    1. >mkdir C:\workspace2
    2. >sencha -sdk C:\tools\ext-6.0.1 generate workspace C:\workspace2
    3. >cd C:\workspace2
    4. >sencha generate package foo
    5. create a js file in packages\local\foo\src\Easy.js. This super simple component extends the Button class and doesn't do anything else.
    6. >cd packages\local\foo
    7. >sencha package build

    The "sencha package build" step fails with:
    Failed to resolve dependency Ext.button.Button for file EasyButton.foo.Easy.


    Sencha v6.1.0.65
    Extjs 6.0.1


    I attached a zip with files package.json, sencha.cfg, and workspace.json.

    I tried adding package.framework=ext to sencha.cfg but it didn't help.

    The goal is to putcomponents shared by multiple applications into packages so they can be managedand shared.

    Help will be greatly appreciated. Thank you,

    Ted
    Attached Files Attached Files

  2. #2
    Sencha User
    Join Date
    Jan 2016
    Posts
    462
    Answers
    60

    Default

    I compared your package.json to an existing one of mine with a component that can build successfully. Change the following:
    Code:
    type:"theme",
    "toolkit": "classic",
    framework": "ext",
    And your package should build. Code packages are usually meant to be included by an app and not built individually.

  3. #3
    Sencha Premium Member
    Join Date
    Mar 2016
    Location
    austin, TX
    Posts
    3

    Default

    Alex, thank you for replying. I can't change "type" to "theme". According to documentation that type is for a package to be used as an application's theme. That is not what I am trying to do. Adding the "toolkit" and "framework" do not help although it does change the error. (I did try adding "type":"theme" as an experiment and it still did not build)[ERR] BUILD FAILED[ERR] com.sencha.exceptions.ExBuild: Timed out waiting for sass build completion[ERR] at com.sencha.command.plugin.PluginManager.execute(PluginMa[ERR] nager.java:104)[ERR][ERR] Total time: 1 minute 34 seconds[ERR] ================= Phantomjs Output =================[ERR] loading page http://localhost:1841/packages/local...uesuccessfully loaded page http://localhost:1841/packages/local...js=trueloading phantomjs adapter== Unhandled Error ==TypeError: undefined is not an object (evaluating 'item.uses.length')

  4. #4
    Sencha User
    Join Date
    Jan 2016
    Posts
    462
    Answers
    60

    Default

    You do need to change it to theme if you want to build it from the package. Also you may want to use Sencha Cmd v6.0.2.14 because of the timeout exception some people are experiencing in 6.1.0.65

  5. #5
    Sencha Premium Member
    Join Date
    Mar 2016
    Location
    austin, TX
    Posts
    3

    Default

    Thanks again Alex.

    I am afraid I don't understand your reply. I want to package some reusable components that are shared between applications. From Sencha's documentation shown below, the package type should be code.

    /**
    * The package type.
    *
    * Sencha Cmd understands the following types of packages:
    * - code : An arbitrary package of code for use by applications or other packages.
    * - theme : A package to be used as an applications theme.
    * - locale : A package containing localization strings or locale-specific code.
    * - template : A package containing one or more templates.
    */

  6. #6
    Sencha Premium Member
    Join Date
    Jan 2008
    Location
    Denmark
    Posts
    28

    Default

    Hi tedbeckett

    Did you resolve this issue?

    I'm having the exact same problem, which is very frustrating.

    The documentation is missing an example of how you would extend an existing component in a package

    Hope you can help me

    Sincerely

    Henrik

  7. #7
    Sencha Premium User wemerson.januario's Avatar
    Join Date
    Nov 2008
    Location
    Goiânia - GO, Brazil
    Posts
    905
    Answers
    15

    Default

    having same problem while building package.

    My idea is to create an universal package (modern/classic toolkits). I am extending some componentes and framework classes

    I need to build package to generate the .pkg file to host it remotel but can't.
    Wemerson Januario @JanuarioCoder
    Novanti Tecnologia, Sencha MVP/ Ext JS Consultant
    ____________________________________________
    Hire me on UpWork:

    GitHub
    https://github.com/wemersonjanuario

    Treinamento e Consultoria Ext JS. QUALIFIQUE-SE JÁ!

Similar Threads

  1. Replies: 0
    Last Post: 15 May 2013, 8:44 PM
  2. sencha app build native vs sencha package build packager.json
    By kramprabhu in forum Sencha Touch 2.x: Discussion
    Replies: 1
    Last Post: 15 May 2013, 12:41 AM
  3. Replies: 11
    Last Post: 29 Oct 2012, 6:16 AM
  4. Replies: 4
    Last Post: 26 Oct 2012, 12:58 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •