ERROR: callback function error Dynamic Components

dynamic
error
bug
components

#1

Hi
When I use Dynamic Componens (created by Sketchup or by me), clicking on “Component options” or “Attribute component” I can’t work because an error appears:

Nessun dato di entità restituito (translation: No given data of entity)

and then:

ERROR: callback function error:Impossibile recuperare la proprietà ‘lenght’ di un riferimento nullo o non definito @dcbridge.js[601]
(translation: Impossible to recover the propriety ‘lenght’ of a null reference or not definied)

If the DC is copied in an empty file, the DC works.
If the DC is copied in a file with other components, the DC does not work.

I try to solve the problem installing the extension “Dynamic Component” , but nothing changed.
What can I do?

I make a test:
I cut and paste the sketchup model with the error from my desktop to the server folder and the DCs work.
What is wrong?


#2

I tag @yogesh of the support team, that has already seen this issue


#3


#4

I am unable to duplicate the behavior demonstrated by @carlobiancon in the animation. Can someone try the same, skp file Dynamic Component error.skp (448.6 KB), and let us know your observations, preferably in Italian SU 2016 ?

Thank you very much for your help! "


#5

this is happening to me also. copy all geometry to a new blank skp file to fix.


#6

Yogesh, I don’t get the callback error, either.


#7

When the Dynamic component is copied to an empty file, no error appears.
When the Dynamic component is copied to a file with other components, the error appears.


#9

Copied and pasted into a different file with components. I still don’t get any errors.

Maybe there’s some other detail we need to know about to reproduce the error.


#10

I format my computer, install Windows 10 Pro, re-install Sketchup16 and now
the issue doesn’t appear.
Mystery!


#11

We are having the same problem. Has a solution been found?


#12

Not yet.
Here other discussion on this case

http://forums.sketchup.com/t/error-on-component-options-window-when-downloading-in-window/19991

http://foro.sketchando.net/viewtopic.php?f=8&t=7221


#13

Carlobiancon
I’m having the same problem, has a solution been found?
I have two computers with sketchup pro 2015, the exact same file generates the problem only on one of the computers (sketchup version 15.3.331 64bit) and not the other one (sketchup 15.1.106 64 bit)


#14

I had that issue too. The solution is pretty simple. Just install the latest version of the Dynamic Components:
https://extensions.sketchup.com/en/content/dynamic-components


#15

Thank you!


#16

Based on prior posts I have isolated the error to ANY lower case “u” occuring in the path leading to a sketchup file. Analysis is as follows:
1.I create a new SU 2018 pro file.
2. I load any dynamic component from the 3D warehouse - for example: "Slide Window (Dynamic Component)"
3. my path contains "usr"
4. Error report when i select dynamic components and component options (for example): Callback function error: unable to get property…@/dcbridge.js[601]
5. I save as the file to the desktop (no lower case u in path).
6. Repeat 1 - 2 and select dynamic components with NO error. Also works if I do the operation on the file saved on desktop.
Please advise status of this error.


#17

Just tested and this is not true. I tested with both the model file and the component file in folders beneath the “Documents” path (which has a lower case “u” in it.)

Also, from a programmer’s perspective, an error only happening if there’s a lower case “u” in the path makes no sense at all. Programmers always allow for paths containing any valid ASCII and Unicode character.
Furthermore, none of the DC functions operate upon or read the path of the model file or the DC component file.


@jeffgerth if you have a component showing an error, please post the component, specify the full error message (including the name of the problem “property”) and state what DC extension version you have installed.


#18

Dan, Thanks for the quick reply- my bad I gave you an incomplete use case and this is on Windows 10 platforms. Please consider these two directory paths:

D:\usr\docs\drawings\client designs\nancy reno

D:\USR\docs\drawings\client designs\nancy reno

In the first one usr has a lower case leading “u” - this will produce the error I mentioned in prior post.

As a correction, rename the “usr” to “USR” - yes this is sadly allowed on windows platform but case is ignored for the path - no need to move any files. You will note with this or any other path that leads with a lower case “u” the error will occur. I believe it will also happen with C:\USR\usr\yourpathtosu_files.

Jeff


#19

#20

Ah … okay … Jim shows that the cause was discovered a year ago … and why this happens …
( Thanks @jim_foltz )

Basically more attention to details when dealing with pathstring separator in Windows file paths is required, and extreme care in the use of double-quoted strings for paths.

In the code I write I always convert "\" to "/" immediately with Window filepaths, so that I don’t get mistaken escaped characters, in this case the "\u" for a unicode character sequence. In the past I’ve often seen errors like this but with "\n" and "\r" (newline and carriage return respectively.)

I’m disturbed to realize it has been a year since it was discovered and it is not yet fixed ?

I guess I should not be surprised as I logged a really stupid bug, that is very easily fixed for Dynamic Components TWO TEARS AND 8 MONTHS AGO ! That was back in v 1.3.2, but it still has not been fixed. See:


Anyway, Jeff, I don’t think this has anything to do specifically with Windows 10, as it was also reported on Win 7.

But I am still wondering why the DC Options dialog would have a fit over the filepath ?

Neither the model filepath nor the DC filepath should have been passed to the dialog Javascript, as there are no DC functions that can do anything with these paths.

I attempted to reproduce on SU2016 (DC v 1.5.0) and SU2014 (DC v 1.3.2) and could not get the error dialog to appear.

But still I do not see the same error you see.

@jeffgerth You said, for example: "Slide Window (Dynamic Component)"
Did you mean ? this

This is wrapped in a worthless outer component that I had to explode to get the DC Options dialog to recognize that it was a DC.


Error Callback function
#21

I feel your pain on this one and since I come from an engineering background I hate to have bugs like this hang around for literally YEARS. In answer to your question about sourcing the error to a cause I don’t see that we have enough transparency into the code to actually identify it, rather we have to infer it. I’d love to see the call stack leading up to the error report for instance. That and a clear understanding of the calling in the ruby wrapped up inside the sketchup. So what I originally saw as my error was with the paths that I shared in the prior post I couldn’t get any DC reports AT ALL. As you know even without a component with a behavioral script you should see the DC console filled out with the various attributes related to the component in focus and I just got errors. So that’s when I tried to do a error analysis by starting an entirely new sketchup file and sucessfully loaded anything that had a DC in it from the library. What I discovered is the other reported wrinkle of this error that’s been reported - a brand new file will work with DC just fine until you save it for the first time (and I had the unfortunate path that would fail). After that I copied one room at a time into the new project and proved that I could change the path and have the error go away - I actually didn’t restore to the original bad path to show that the SU file has nothing to do with this error but that is my belief.

I’d be happy to file a formal bug report with a use case that will fail and one that won’t but I’d like the programming staff for SU to be involved and confirm - do we get that kind of access or is this just us folks out in the forest, so to speak.