Sencha Architect framework error: DOM element with id X is not the same as element in the DOM. Make sure to clean up element instances using destroy() - dom

Sencha Architect can not display anything in the preview. When I build and run my application, everything works just fine.
But inside Architect, I get the following error:
DOM element with id X is not the same as element in the DOM. Make sure to clean up element instances using destroy()
I don't know why that happens, has anyone experienced anything similar?

Related

Can't get the DOM in a react app using testcafe

I'm new into testcafe. I have a react app which was made by create-react-app, and I'm trying to do very simple function:
await t.expect(ReactSelector('ReactHighcharts').exists.ok()
I figured out that no matter what component I put inside the selector I get flase.
When I explored more, I saw that react-scripts probably minifies/uglifies by his webpack, my code, and that's
why I can't get the DOM.
Am I right? if yes - how can I disable it? if not, I'd like to understand why the DOM is unreachable.
You can explicitly set the displayName property for a component or consider testing the dev build.
https://reactjs.org/docs/react-component.html#displayname

React does not recognize the `transitionAppear` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute

I am using the redux-form-material-ui DatePicker as described in the docs. However it just throws these errors.
React does not recognize the transitionAppear, transitionAppearTimeout, transitionEnter and transitionEnterTimeout props on DOM element...
I checked it in the developer tools and these transition properties are actually passing down to the child div from it's parent CSSTransitionGroup.
Due to this, the DatePicker dialog is not working as expected. I have already spent more than a day on this but can't seem to get it working. Please help me out!
The exact Bug you are reporting is discussed here: "Unknown props transitionAppear, transitionAppearTimeout, transitionEnter, transitionEnterTimeout and ripples #9328".
User kaytrance said: "It turned out that material-ui uses react-transition-group v1.x, but a chart library that I use has dependency on v2.x. So I had to put an older version of chart library in order to get rid of that errors.".
A further comment from user kevincolten was: "You can bring in both react-transition-groups in your package.json
"react-transition-group": "^1.2.0",
"react-transition-group-v2": "npm:react-transition-group",
".
The example given in your question runs fine on my browser.
Since you haven't provided your code (and modifications?) or a CodeSandbox (which is OK for me) I had to use a different example to reproduce the same error and determine the appropriate fix.
I get from this sandbox:
Warning: render(): Rendering components directly into document.body is discouraged, since its children are often manipulated by third-party scripts and browser extensions. This may lead to subtle reconciliation issues. Try rendering into a container element created for your app.
Warning: React does not recognize the staticContext prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase staticcontext instead. If you accidentally passed it from a parent component, remove it from the DOM element.
in a (created by Link)
in Link
in CourseLink (created by Route)
in Route (created by withRouter(CourseLink))
in withRouter(CourseLink) (created by Course)
in li (created by Course)
in ul (created by Course)
in div (created by Course)
in Course (created by Route)
in Route (created by BasicExample)
in div (created by BasicExample)
in Router (created by BrowserRouter)
in BrowserRouter (created by BasicExample)
in BasicExample
No Results
That error was reported here "React does not recognize the staticContext prop on a DOM element".
The suggested fix from user timdorr is:
"You should do what NavLink does and wrap it in a Route inside CourseLink: https://github.com/ReactTraining/react-router/blob/master/packages/react-router-dom/modules/NavLink.js ".
The Animation-Add-on isn't recognized.
That is due to the incorrect dependency, loading both is easier than fixing the one.

Web browser hangs upon Drag And Drop Keyword for robot framework

I am currently using Robot Framework to automate my test cases. In one of the test cases I have, I need to drag and drop a certain element. Upon using the SeleniumLibrary keyword Drag And Drop, my browser just hangs. Has anyone encountered this same error? Is there a work around I can use?
I am using Robot Framework 2.7 and running my tests on IE8 and FF9.
Here is sample code:
Wait Until Keyword Succeeds 10s 5s Element Should Be Visible
//td[#class='policy_td']//ul[#class='workgroup_list']
Drag And Drop //ul[#id='unused_workgroup_ul']//li[#class='workgroup']//span//span[text()='Test'] target=//td[#class='policy_td']//ul[#class='workgroup_list']
I had the same problem today. You should define element by locator using xpath, and later use it as the target. For example, part of your code could look like:
Assign Id To Element xpath=//td[#class='policy_td']//ul[#class='workgroup_list'] ID
Drag And Drop //ul[#id='unused_workgroup_ul']//li[#class='workgroup']//span//span[text()='Test'] target=ID

iPhone webdriver not locating element using CSS selector

iPhone webdriver is not able to locate DOM elements using CSS selectors. I'm running the test on iPad simulator. In news.yahoo.com, trying to select an element using findElement(By.cssSelector()).
None of the below works. I can locate the element by id and xpath but css selector doesn't work. Getting no such element exception. Is this is a known issue? Any pointer would be helpful. Thanks!
findElementByCssSelector("mediamostpopular")
or
findElement(By.cssSelector("mediamostpopular"))
or
executeScript("document.querySelector('#mediamostpopular');"));
With the Given Information I am able to see the ID #mediamostpopular.
In Selenium We can find the element given below as follows.
driver.findElement(By.id("mediamostpopular")).

body.onload and GWT onModuleLoad launch order

According to this FAQ, when GWT bootstraps, onModuleLoad is supossed to run before HTML body's onload event. The process detailed within that FAQ works like this:
1. The HTML document is fetched and parsing begins.
...
9. externalScriptOne.js completes. The document is ready, so onModuleLoad() fires.
...
12. body.onload() fires, in this case showing an alert() box.
But in my tests, i have checked that it doesnt work this way. Or at least not in every browser (oddly, Google Chrome in particular doesn't stick to this kind of behaviour). For example, I have this little test involving onModuleLoad and body.onLoad:
public void onModuleLoad() {
runTestFunction();
}
private native void runTestFunction() /*-{
console.log("GWT's onModuleLoad");
$wnd.loaded=true;
}-*/;
And:
<body onload="console.log('body.onLoad');if(loaded!=null) console.log('loaded var is set');">
If i launch firefox, and run this example, the console will show this:
GWT's onModuleLoad
body.onLoad
loaded var is set
But in Chrome:
body.onLoad
Uncaught ReferenceError: loaded is not defined
GWT's onModuleLoad
In the latter, onModuleLoad runs the last, thus "loaded" var is not yet available and body.onLoad code cant use it.
And what Im trying to achieve? I want some handwritten Javascript that runs within body.onload to interact with my GWT code. In this example i use this dummy "loaded" var, but in the future it should be able to call GWT functions written in Java. The problem is that i need to make sure that onModuleLoad runs first so it can export the variables and methods for javascript to access them.
So, what am i missing? Is this behaviour as unreliable as it looks like, or am i doing something wrong?
PS: i have a plan B to achieve this which is proved to work, but first i want to make sure that it isnt possible to do it this way since this should be the preferred method.
First, the latest version of the doc is at http://code.google.com/webtoolkit/doc/latest/DevGuideOrganizingProjects.html#DevGuideBootstrap
And it says (even the GWT 1.5 version you were looking at) that "onModuleLoad() can be called at any point after the outer document has been parsed", which includes before and after window.onload.
As the doc says, GWT loads your code in an iframe (used here as a sandbox), which is asynchronous; so your code loads when both the iframe and the "body" are loaded. Depending on the time needed to load the iframe, that can be before or after window.onload (in the example, they assume it loads right away, which could be the case when the *.cache.* file is effectively in the browser's cache).
But the rule of thumb is that GWT tries hard (at least the built-in linkers) to make things start asynchronously so that it doesn't break loading of other external resources (stylesheets and images, for instance). That implies that it cannot be guaranteed to run before the window.onload (they could have guaranteed to run after window.onload, but why wait?)