Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/319.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 错误:";内容安全策略指令:“;框架祖先';自我'&引用;尝试在Jupyter笔记本中创建iframe时_Python_Iframe_Jupyter Notebook_Jupyter_Jupyter Lab - Fatal编程技术网

Python 错误:";内容安全策略指令:“;框架祖先';自我'&引用;尝试在Jupyter笔记本中创建iframe时

Python 错误:";内容安全策略指令:“;框架祖先';自我'&引用;尝试在Jupyter笔记本中创建iframe时,python,iframe,jupyter-notebook,jupyter,jupyter-lab,Python,Iframe,Jupyter Notebook,Jupyter,Jupyter Lab,我得到一个错误: Refused to frame 'http://localhost:8888/' because an ancestor violates the following Content Security Policy directive: "frame-ancestors 'self'". 尝试从包含另一个本地HTML文件的iframe的本地HTML文件创建iframe时 例如测试outer.html: 使用Jupyter笔记本Python代码: fr

我得到一个错误:

Refused to frame 'http://localhost:8888/' because an ancestor violates the following Content Security Policy directive: "frame-ancestors 'self'".
尝试从包含另一个本地HTML文件的iframe的本地HTML文件创建iframe时

例如
测试outer.html


使用Jupyter笔记本Python代码:

from IPython.display import IFrame
IFrame(src='test-outer.html', width=200, height=200)
test-inner.html
可以包含任何内容

测试outer.html
在单独的浏览器选项卡上完全加载。问题是将其加载到Jupyter笔记本中。