Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Retrieving Dapps list fail #2868

Closed
chevdor opened this issue Oct 25, 2016 · 10 comments
Closed

Retrieving Dapps list fail #2868

chevdor opened this issue Oct 25, 2016 · 10 comments
Labels
F2-bug 🐞 The client fails to follow expected behavior.

Comments

@chevdor
Copy link

chevdor commented Oct 25, 2016

version Parity/v1.4.0-unstable-135d5d0-20161025/x86_64-macos/rustc1.12.1

1 single dapps in ~/.parity/dapps made from https://github.com/chevdor/generator-ethdapp

The manifest is:

{
    "id": "MyKillerDapp",
    "name": "My Killer Dapp!",
    "description": "I know this is a pain...",
    "version": "0.1.0",
    "author": "Will",
    "iconUrl": "images/title.png"
}

Error in the dev console:

app list SyntaxError: Unexpected token < in JSON at position 0(anonymous function) @ available.js:84
registry.js:72 lookupAddress dappreg 0x7bbc4f1a27628781b96213e781a1b8eec6982c1db8fac739af6e4c5a55862c03 0x11e869F9094a1101B4C60201d6Cf894AfC7EadBB

which is the catch below:

function () {
  return fetch(_environment.parityNode + '/api/apps').
  then(function (response) {
    return response.ok ?
    response.json() :
    [];
  }).
  catch(function (error) {
    console.warn('app list', error);
    return [];
  }).
  then(function (localApps) {
    return builtinApps.
    concat(localApps.filter(function (app) {return !['ui'].includes(app.id);})).
    sort(function (a, b) {return a.name.localeCompare(b.name);});
  });
};
@jacogr jacogr added F2-bug 🐞 The client fails to follow expected behavior. M5-ui labels Oct 25, 2016
@jacogr
Copy link
Contributor

jacogr commented Oct 25, 2016

Thank you. Will confirm and push up a fix.

@chevdor
Copy link
Author

chevdor commented Oct 25, 2016

Thanks for the update @jacogr.
If you need to generate quickly (like in 15s) a bunch of dapps, check out https://github.com/chevdor/generator-ethdapp it may help for the testing.

In case the format of the dapps (manifest, naming, etc...) has evolved, please let me know and I will update the yeoman template.

@jacogr
Copy link
Contributor

jacogr commented Oct 25, 2016

No the formats are still exactly the same - we had some issues for 2 days where the integration builds between the Rust & JavaScript were not quite updating as expected, so while we should be testing these locally, chances are that when we did these we have either newer or outdated (working) versions.

It should be working as expected, chances are that is is already fixed, just not available in a built version yet :( Either way, need to make sure the right stuff is included and test to see that it does what it is supposed to.

Sorry about this, but really do appreciate the report so we can fix it and not have it rear its ugly little head again. As an aside, will add one of your generated dapps to my instances (and point the team to do the same), very easy to get going and make sure we cover a bit of a wider spectrum.

@chevdor
Copy link
Author

chevdor commented Oct 25, 2016

@jacogr I built from master a few minutes before reporting the issue so unless in another branch, it may still be around.

Don´t be sorry! I am using master... nothing to complain about as it may be work in progress.

Regarding the yeoman template, the one I provide is really basic. If you see an interesting use case for alternate templates, let me know. It is possible to create multiple generator (ie sub generators).

Keep up with the great work!

@chevdor
Copy link
Author

chevdor commented Oct 26, 2016

Just FYI, as of today, the list of dapps is now getting populated, yeah! I do not see the images though and the web3 seems to not longer be injected properly (or not as it used to be).

@jacogr
Copy link
Contributor

jacogr commented Oct 26, 2016

Thanks for the update - I was just about to respond that I'm struggling to reproduce.

We actually just fixed the inject.js issue, https://github.com/ethcore/parity/issues/2872 - my generated "Killer Bunny App" works as expected. So I think you just missed the push where it was fixed. It really should be operational now.

@jacogr
Copy link
Contributor

jacogr commented Oct 26, 2016

I can verify the missing images, definately a bug, logged here - https://github.com/ethcore/parity/issues/2889

@chevdor
Copy link
Author

chevdor commented Oct 26, 2016

ok, I am rebuilding and update you. As soon as I see the full list and the images, I will close this issue. Since I keep an eye on that part of the UI, count on me to reopen in case of regressions.

@jacogr
Copy link
Contributor

jacogr commented Oct 26, 2016

Images will only be merged later today once it has gone through PR review, but small one, got lost somewhere in the shuffle.

@chevdor
Copy link
Author

chevdor commented Oct 26, 2016

OK, so I close this one since you opened an issue for the images. Indeed, as of now, I see that the images do not appear (yet).

@chevdor chevdor closed this as completed Oct 26, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
F2-bug 🐞 The client fails to follow expected behavior.
Projects
None yet
Development

No branches or pull requests

2 participants