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

new installation problem #67

Open
denimaaark opened this issue Nov 10, 2015 · 7 comments
Open

new installation problem #67

denimaaark opened this issue Nov 10, 2015 · 7 comments

Comments

@denimaaark
Copy link

Hello, i have installed new versions of aurelia and grid.

I have errors when included plugin aurelia-bs-grid

Unhandled promise rejection Error: (0 , _aureliaFramework.skipContentProcessing) is not a function(…)(anonymous function) @ es6.promise.js:138
es6.promise.js:138 Unhandled promise rejection Error: (0 , _aureliaFramework.skipContentProcessing) is not a function(…)(anonymous function) @ es6.promise.js:138
es6.promise.js:138 Unhandled promise rejection Error: (0 , _aureliaFramework.skipContentProcessing) is not a function(…)

@jmjf
Copy link
Contributor

jmjf commented Nov 13, 2015

Looking at this, it seems like changes from 0.0.4 vs master. I'm guessing Aurelia, being pre-beta, is evolving faster than developers can release updates to address breaking API changes.

The quick fix for this particular problem is, in package.json find the line for aurelia-bs-grid, which will look something like:

"charlespockert/aurelia-bs-grid": "github:charlespockert/aurelia-bs-grid@^0.0.4",

replace the @^0.0.4 with @master

Do the same in config.js.

This may or may not solve your problem. I'm getting a different error now that doesn't reference aurelia-bs-grid, but that goes away when I remove the .plugin() line for aurelia-bs-grid, so is obviously related to aurelia-bs-grid.

Unhandled promise rejection
Error: Error invoking TaskQueue. Check the inner error for details. ------------------------------------------------ 
inner error: 
makeRequestFlushFromMutationObserver@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-task-queue.js:13:20 
TaskQueue@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-task-queue.js:59:41 
invoke@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:334:14 
invoke@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:309:155 
invoke@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:557:16 
get@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:145:27 
get@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:488:18 
invoke@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:354:23 
invoke@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:309:155 
invoke@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:557:16 
get@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:145:27 
get@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-dependency-injection.js:488:18 
initialize@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-templating.js:3109:30 
initialize@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-templating.js:2337:7 
initialize@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-templating.js:2256:9 
importViewResources/<@http://localhost:9000/jspm_packages/github/aurelia/[email protected]/aurelia-templating.js:2617:11 
l/</h@http://localhost:9000/jspm_packages/npm/[email protected]/client/shim.min.js:1773:66 
l/<@http://localhost:9000/jspm_packages/npm/[email protected]/client/shim.min.js:1778:19 
e@http://localhost:9000/jspm_packages/npm/[email protected]/client/shim.min.js:1958:55 

I also note that when I install with jspm, aurelia-bs-grid uses different versions than the latest Aurelia skeleton, so it may be some conflict related to that. (task-queue above is 0.8.0, but skeleton 0.20.0 uses 0.9.0, so there are two different versions, possibly creating conflicts.) I'm going to try to step back to skeleton 0.19.0 and see if that resolves anything. More to come.

@jmjf
Copy link
Contributor

jmjf commented Nov 13, 2015

Followup: Using Skeleton 0.19.0 instead of 0.20.0 looks like it will solve the problems, maybe. I'm down to an issue with aurelia-http-client:

Unhandled promise rejection
TypeError: _this.XHRType is not a constructor

It is pulling newer versions of a couple of Aurelia packages, so I'm guessing it needs to be forced to a newer version too. Or maybe swapped out for the fetch client. Hopefully, I'll get this working today.

NOTE: all the samples except remote data work fine.

After, I may try to beat together a 0.20.0 compatible branch, but want to see the unmodified code working first so I know what the issues are. Although, given official beta's impending release (according to the latest on the Aurelia blog), it may be wiser to wait until that's settled.

@denimaaark
Copy link
Author

thanks for help, i have try with master but still not working ...
i will wait an update ...

@jmjf
Copy link
Contributor

jmjf commented Nov 13, 2015

After further research, aurelia-templating 0.17.0 removes viewSlot.swap(). See
this blog post and this commit. Apparently, no one uses viewSlot.swap()... except aurelia-bs-grid (oops). So I copied the viewSlot.swap() code and worked it into grid.js.

Then I discovered that bindingEngine is now BindingEngine, set up to inject it, but the grids in the sample all come up blank, so I'm guessing I'm doing something wrong and don't understand what's going on well enough to untangle it.

@charlespockert: If it helps get this plugin functioning with current versions of Aurelia, you can see my work on the plugin so far at: https://github.com/jmjf/aurelia-bs-grid/tree/skeleton-0.20.0. I've also pushed the repo I've been using to test at https://github.com/jmjf/skel-0.20.0--which is navigation-skeleton 0.20.0 with the aurelia-bs-grid sample app copied to src, aurelia-http-client 0.13.0, and aurelia-bs-grid from my repo's skeleton-0.20.0 branch.

@denimaaark: Until this repo is updated, you can clone the navigation-skeleton repo, checkout 0.19.0, npm install, jspm install and jspm install github:charlespockert/aurelia-bs-grid@master and it should work. I was able to get the sample app working with those versions and [email protected] and a few adjustments to config.js (to add the css alias for systemjs/[email protected]) and main.js (adding charlespockert/ to the plugin line).

@jmjf
Copy link
Contributor

jmjf commented Nov 15, 2015

The skeleton-0.20.0 branch of https://github.com/jmjf/aurelia-bs-grid/tree/skeleton-0.20.0 is fixed for skeleton 0.20.0, I think.

After updating the dependencies, there were three breaking API changes between skeleton 0.19.0 and 0.20.0.

I fixed the bindingEngine -> BindingEngine change noted above by injecting BindingEngine and assigning it to this.bindingEngine and replacing the one use of bindingEngine with this.bindingEngine.

I fixed the viewSlot.swap() removal by copying the code from skeleton 0.19.0 and making minor adjustments to fit the context.

The major issue turned out to be a change in the API for ViewFactory.create(). In the previous release, it accepted a bindingContext parameter. In the current release, bindingContext must be set after the view is created with view.bind(bindingContext). That is why nothing displayed in the grid container in the previous note. It works for all examples, I think.

See Pull #69 and the repo branch noted above for details.

Scary thing is, I think I'm staring to understand Babelified ES5.

@charlespockert
Copy link
Owner

I always look at the ES5 and not the pre-transpiled code :) - you get used to it

Thanks for the work so far!

@marcoalfaro
Copy link

Charles, very nice grid. Sadly it doesn't work on Aurelia 1.0.1 with installation issues
Are you planning to fix it for the latest version of Aurelia?

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

4 participants