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

Failed propType warning in v5.0.7 #167

Closed
cuongluu8 opened this issue Jul 19, 2017 · 8 comments
Closed

Failed propType warning in v5.0.7 #167

cuongluu8 opened this issue Jul 19, 2017 · 8 comments

Comments

@cuongluu8
Copy link

I'm still getting the following warning in the console

Warning: Failed propType: Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them.

I'm using react 0.14.7

@cuongluu8
Copy link
Author

if I roll back to version 3.3.1 (before the prop-types dependency was added) this warning goes away.
This means the latest 5.x version is no longer compatible with v0.14.7?

@Andarist
Copy link
Owner

You are trying to call one of the PropTypes validators - typeof PropTypes.string === 'function', but they are not supposed to be executed by you, but by a library. You need to check your code, the easiest way to do so would be just to put a breakpoint in the place of the warning and just trace back the actual function call which has caused it.

@cuongluu8
Copy link
Author

cuongluu8 commented Jul 19, 2017

Done that - I'm pretty sure I am not doing that.
Also if I removed the autosize component then I do not get this warning

@Andarist
Copy link
Owner

Could u share ur code on something like codesandbox.io then?

@cuongluu8
Copy link
Author

https://codesandbox.io/s/qxq8G1Gp
Inspect the console for the error/warning

@Andarist
Copy link
Owner

Thanks for sharing, from what I see you should upgrade ur React version to v0.14.9 . More can be read here - facebook/prop-types#26

@cuongluu8
Copy link
Author

Yep - we'll probably upgrade to v15 in the future, but unfortunately we're stuck on 0.14.7 at the moment.

@Andarist
Copy link
Owner

In the meantime u can try to upgrade to v0.14.9, it shouldnt bring any breaking changes and it will get rid of those warnings.

tanak added a commit to tanak/patriot-workflow-scheduler that referenced this issue Jul 26, 2017
zenmyo pushed a commit to CyberAgent/patriot-workflow-scheduler that referenced this issue Jul 26, 2017
* Fix to modify start_datetime

* Change function name to clarify objectives

* Add edit job info function

* Upgrade react version

to solve the issue of
Andarist/react-textarea-autosize#167
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

2 participants