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

Script error with Report Window #4

Closed
dietervermeulen opened this issue Sep 21, 2016 · 31 comments
Closed

Script error with Report Window #4

dietervermeulen opened this issue Sep 21, 2016 · 31 comments
Assignees

Comments

@dietervermeulen
Copy link

When running the script with the Report Window, I get a Script error (see screen shots) and at the end the window is empty.
image
image
image

@josols
Copy link

josols commented Sep 21, 2016

Same with me. Win 7, dynamo 1.1 for Revit.

@ksobon
Copy link
Owner

ksobon commented Sep 21, 2016

@dietervermeulen and @josols here's a link to Mandrill Primer that explains how the data needs to be structured for Parallel Coordinates Chart. https://konradsobon.gitbooks.io/mandrill-primer/content/parallelCoordinates.html

Here's your sample re-worked to match that structure.

image

image

Good luck!

@ksobon ksobon closed this as completed Sep 21, 2016
@ksobon ksobon self-assigned this Sep 21, 2016
@dietervermeulen
Copy link
Author

Hi Konrad,
Thanks for indicating the solution with the names. But still the scripting error remains.
image

@ksobon ksobon reopened this Sep 21, 2016
@ksobon
Copy link
Owner

ksobon commented Sep 21, 2016

can you do two things for me?

  1. check if that path that is being mentioned in the error actually points at the d3.v3.min.js file.
  2. just click yes, and then right click in the empty window and click on View Source. Can you post the source code from that window?

@dietervermeulen
Copy link
Author

dietervermeulen commented Sep 21, 2016

  1. The path exists yes.
    image
  2. Source code: in attachment below.
    Source Code.txt

PS: Executed in Dynamo Studio 2017

@ksobon
Copy link
Owner

ksobon commented Sep 21, 2016

OK, so the script looks just fine, and if the file exists I can only suggest one more thing. Please try closing Studio and firing it up in Dynamo Sandbox. That's the version that I am testing on. I did run into this issue before when firing up Mandrill from Revit, but found no solution yet. Here's a link to my conversation with Dynamo dev team: DynamoDS/DynamoRevit#1143

Ps. I tested that file trying to launch it from Dynamo inside of Revit and it fails for me as well. I still have no idea why it won't work when launched from within Revit but works just fine in Sandbox.

@dietervermeulen
Copy link
Author

Does not work in any of the versions: Revit Dynamo, Dynamo Sandbox or Dynamo Studio (the last one is in fact now also the Dynamo Core which is the same as the Sandbox.)...

@ksobon
Copy link
Owner

ksobon commented Sep 21, 2016

it seems to be working in at least one of these versions:
image

I know it has an issue with running on top of Revit. I am looking at that. I don't have Studio so I can't test on that.

@dietervermeulen
Copy link
Author

dietervermeulen commented Sep 21, 2016

Which is exactly the version I use :-)
Sorry, but not working in the Sandbox version on my machine over here. Could it be related to Javascript version?

@ksobon
Copy link
Owner

ksobon commented Sep 21, 2016

OK, I will keep this issue open, but I am not sure how I can debug your issue without being able to re-create it.

I am on Win7 at work and Win10 at home so operating system is probably not an issue. I guess that it has to do with what app owns the window which in turn sets the context for data. I will try looking at that if I hear from more people that they can't get it to work on their machines.

@ksobon ksobon added the bug label Sep 21, 2016
@ricardyn
Copy link

The same happens with me.

@ricardyn
Copy link

@ksobon the problem can be the path? Because the file is on the correct place.

image

image

@ksobon
Copy link
Owner

ksobon commented Sep 23, 2016

@ricardo7cordas that's not an issue. That's an error that is being thrown for every exception that happens inside of d3.js I checked that the path is fine, and it was escaped inside of code so the actual path doesn't have %20 in it but a space. Please see the TXT attached by @dietervermeulen in above comment. I have no idea what causes that error and I have very little to go on here. Sorry.

@ricardyn
Copy link

Ok @ksobon . Thanks for your effort

@plindjo
Copy link

plindjo commented Sep 24, 2016

Hi Konrad. I am unfortunately experiencing the same issue with all charts. I've tested with sandbox and revit on win7 enterprise and win10 home, and got the script error with every setup (d3 is undefined). Since you can't recreate the issue, I thought it might be some weird reference issue or something, and figured I'd try building the package from the source.
Unfortunately the Mandrill_d3 project will not compile since the parallelCoordinatesChart.html is missing from the repo. If you can add it, I will try to investigate further :-)
Cheers Peter

@ksobon
Copy link
Owner

ksobon commented Sep 26, 2016

I think I know what the issue is. I am using a WebBrowser control to render these charts and in all its greatness its no different than using an IE7 which might or might not work on each individual person's computer depending on their own setup. Also, i found that WebBrowser control usually has trouble and unpredictable behavior when it comes to using local resources (d3.js) and it frequently denies access to these resources. I need to implement a different web browser and preferably one based on Chrome or FireFox. Currently I am looking into things like CefSharp, Awesomium and EO.WebBrowser. I will let you guys know when I have figured out which of these will fix the issue here. Thanks for the patience.

@ksobon
Copy link
Owner

ksobon commented Sep 27, 2016

OK, I tested my assumption using a EO.WebBrowser which uses Chrome and it turns out that I was correct. I can get my charts working now, in Sandbox and Revit without any errors. It turns out that It was about security restrictions and how browsers disable any website javascripts from accessing local files. What is possible with the EO browser is that it allows you to disable that and access the local d3.js files. Also it would mean consistency since it will no longer be dependent on what IE browser is installed on user computer since EO chrome browser would be distributed with Mandrill as a DLL file.

There is one small issue though. EO charges $700 for a license. Without it, it works but will show a little window in the corner of the screen:
image

It's not actually embedded in the chart window, and you can move your chart to a different screen so its not a big deal, but still just slightly annoying.

Let me know what you guys think. I will post an update with this new browser solution for you all to test. Feedback is welcome.

@plindjo
Copy link

plindjo commented Sep 27, 2016

Great job! Looking forward to trying it out

@dietervermeulen
Copy link
Author

Sounds good to me too, as long as their are no legal issues with this use of the license?

Op 27 sep. 2016 om 17:40 heeft Konrad K Sobon <notifications@github.commailto:notifications@github.com> het volgende geschreven:

OK, I tested my assumption using a EO.WebBrowser which uses Chrome and it turns out that I was correct. I can get my charts working now, in Sandbox and Revit without any errors. It turns out that It was about security restrictions and how browsers disable any website javascripts from accessing local files. What is possible with the EO browser is that it allows you to disable that and access the local d3.js files. Also it would mean consistency since it will no longer be dependent on what IE browser is installed on user computer since EO chrome browser would be distributed with Mandrill as a DLL file.

There is one small issue though. EO charges $700 for a license. Without it, it works but will show a little window in the corner of the screen:
[image]https://cloud.githubusercontent.com/assets/529781/18880749/fbd957f6-84a6-11e6-9a4b-bd946aab016a.png

It's not actually embedded in the chart window, and you can move your chart to a different screen so its not a big deal, but still just slightly annoying.

Let me know what you guys think. I will post an update with this new browser solution for you all to test. Feedback is welcome.

You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com//issues/4#issuecomment-249904315, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ALiSuY0dZuGPpZocaJP9BYV5Njf8jgL1ks5quTjigaJpZM4KChnc.

@ksobon
Copy link
Owner

ksobon commented Sep 27, 2016

I would rather purchase the license and then it states that its perfectly legal to ship their DLLs with the application. I am sure its OK to ship the free version as well but the pop-up is annoying.

I need to raise some founds for this. I don't think I want to start investing $$$ and time into my Open Source projects...

@andydandy74
Copy link

kickstarter

@ksobon
Copy link
Owner

ksobon commented Sep 27, 2016

latest release should address issues raised here

image

@ricardyn
Copy link

the error continues, even after the update.

image

image

@ksobon
Copy link
Owner

ksobon commented Sep 28, 2016

Ricardo, try the chrome window node. This one didnt change.

@ricardyn
Copy link

ricardyn commented Sep 28, 2016

wow.. thats great.. it works!!!

after the second run of the same graph, the little EO Browser window does not appear.. this is fine to me.

image

@ksobon
Copy link
Owner

ksobon commented Sep 28, 2016

Now i need to somehow solicit $700 to make the small window in bottom right corner go away. Lol. Glad it works for you.

@ksobon ksobon closed this as completed Sep 28, 2016
@ricardyn
Copy link

We will ask for donations. I do advertising here with the guys from Brazil if necessary. And also contribute with $$$. This is an amazing job.

@ksobon
Copy link
Owner

ksobon commented Sep 28, 2016

I was thinking about starting a small fundme.com project so people can contribute. Lol. I will set something up. I need to fix a few more bugs and i will set that up. Thanks for the offer!

@ricardyn
Copy link

Let's do it.

@dietervermeulen
Copy link
Author

dietervermeulen commented Sep 28, 2016

Works fine now ! Great job Konrad.

@ksobon
Copy link
Owner

ksobon commented Sep 29, 2016

Here's a link to a fund if you guys want to contribute: https://funds.gofundme.com/dashboard/mandrill

Thanks!

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

6 participants