gpt4 book ai didi

sublimetext3 - Xdebug 上下文没有显示任何内容并且浏览器一直在加载?

转载 作者:行者123 更新时间:2023-12-01 03:14:51 26 4
gpt4 key购买 nike

我正在使用 sublimet-text-3 和 xdebugclient 但 Xdebug 上下文窗口不显示任何内容,浏览器不断加载,每当我单击 sublime 文本上的任何内容时,断点变成黄色箭头,上下文窗口中没有显示任何内容。
这是我的 sublime 控制台输出:

File "./python3.3/threading.py", line 901, in _bootstrap_inner
File "xdebug.session in /home/mohit/.config/sublime-text-3/Installed/Xdebug Client.sublime-package", line 148, in run
File "xdebug.session in /home/mohit/.config/sublime-text-3/Installed Packages/Xdebug Client.sublime-package", line 240, in execute
File "xdebug.session in /home/mohit/.config/sublime-text-3/Installed Packages/Xdebug Client.sublime-package", line 271, in get_context_values
File "xdebug.protocol in /home/mohit/.config/sublime-text-3/Installed Packages/Xdebug Client.sublime-package", line 195, in read
File "./python3.3/xml/etree/ElementTree.py", line 1356, in XML
File "<string>", line None
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 2, column 327

这是我的用户 Xdebug.sublime-settings
{
// For remote debugging to resolve the file locations
// it is required to configure the path mapping
// with the server path as key and local path as value.
//
// Make sure to use absolute path when defining server path,
// because Xdebug debugger engine does not return symbolic links.
//
// Example:
// "/absolute/path/to/file/on/server" : "/path/to/file/on/computer",
// "/var/www/htdocs/example/" : "C:/git/websites/example/"
"path_mapping": {

},

// Determine which URL to launch in the default web browser
// when starting/stopping a session.
"url": "",

// An IDE key is used to identify with debugger engine
// when Sublime Text will start or stop a debugging session.
//
// This package does not filter sessions by IDE key,
// it will accept any IDE key, also ones that do not match this configured IDE key.
// It is merely used when launching the default web browser with the configured URL.
"ide_key": "sublime.xdebug",

// Host address of network interface which Sublime Text
// should listen to connect with debugger engine.
//
// By specifying "" or "0.0.0.0" as host address, Sublime Text
// will listen on all the configured network interfaces.
// This is the desired configuration when debugging
// a script that is located on a remote server.
//
// Otherwise it is recommended to use "127.0.0.1" or "localhost"
// as configuration, when debugging a script on your local machine.
// Due to the fact that by listening on all the configured
// network interfaces raises a security concern as anyone
// can access Sublime Text through the configured port.
//
// When specifying host address of network interface,
// be sure to specify an IPv4 address as Sublime Text
// will listen for connections through an IPv4 socket.
"host": "",

// Which port number Sublime Text should listen
// to connect with debugger engine.
"port": 9000,

// Maximum amount of array children
// and object's properties to return.
"max_children": 32,

// Maximum amount of
// variable data to initially retrieve.
"max_data": 1024,

// Maximum amount of nested levels to retrieve
// of array elements and object properties.
"max_depth": 1,

// Break at first line on session start, when debugger engine has connected.
"break_on_start": false,

// Break on exceptions, suspend execution
// when the exception name matches an entry in this list value.
"break_on_exception": [
// E_ERROR, E_CORE_ERROR, E_COMPILE_ERROR, E_USER_ERROR
"Fatal error",
// E_RECOVERABLE_ERROR (since PHP 5.2.0)
"Catchable fatal error",
// E_WARNING, E_CORE_WARNING, E_COMPILE_WARNING, E_USER_WARNING
"Warning",
// E_PARSE
"Parse error",
// E_NOTICE, E_USER_NOTICE
"Notice",
// E_STRICT
"Strict standards",
// E_DEPRECATED, E_USER_DEPRECATED (since PHP 5.3.0)
"Deprecated",
// 0
"Xdebug",
// default
"Unknown error"
],

// Always close debug windows and restore layout on session stop.
"close_on_stop": false,

// Show information about super globals in context view.
"super_globals": true,

// Display property by fullname in context view.
"fullname_property": true,

// Do not show possible password values in context view.
"hide_password": false,

// Render evaluated result as parsed output instead of raw XML.
"pretty_output": false,

// Always launch browser on session start/stop.
// Note: This will only work if you have the 'url' setting configured.
"launch_browser": false,

// When launching browser on session stop do not execute script.
// By using parameter XDEBUG_SESSION_STOP_NO_EXEC instead of XDEBUG_SESSION_STOP.
"browser_no_execute": false,

// Do not use the debugging window layout.
"disable_layout": false,

// Window layout that is being used when debugging.
"debug_layout" : {
"cols": [0.0, 0.5, 1.0],
"rows": [0.0, 0.7, 1.0],
"cells": [[0, 0, 2, 1], [0, 1, 1, 2], [1, 1, 2, 2]]
},

// Group and index positions for debug views.
"breakpoint_group": 2,
"breakpoint_index": 1,
"context_group": 1,
"context_index": 0,
"stack_group": 2,
"stack_index": 0,
"watch_group": 1,
"watch_index": 1,

// Custom gutter icons for indicating current line or enabled/disabled breakpoints.
//
// Do not use same icon for following values, because Sublime Text is unable
// to use the same icon for different scopes, in case there are duplicate icons
// detected it will fall back to the corresponding icon in the package.
"breakpoint_enabled": "circle",
"breakpoint_disabled": "dot",
"breakpoint_current": "",
"current_line": "bookmark",

// Path to Python installation on your system.
// Which is being used to load missing modules.
//
// It is recommended to configure your Python path for Sublime Text 2
// especially on older UNIX systems, where some modules (xml.parsers.expat)
// might be missing and could improve performance of package.
//
// Example:
// "python_path" : "/usr/lib/python2.7"
"python_path" : "",

// Show detailed log information about communication
// between debugger engine and Sublime Text.
// Log can be found at Packages/User/Xdebug.log
"debug": true
}

最佳答案

我不确定这是否是同样的问题,但 xdebug 最近在 Sublime 中停止为我工作。我有一个类似的错误:

xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 2, column 296

上下文窗口是空的,我无法通过。

我终于确定是 xdebug 2.6.0 导致了这个问题。当我恢复到 2.5.5 时,它又开始完美运行了。

我的开发环境使用 vagrant/virtualbox,所以我编译了 2.5.5 并创建了一个脚本来在启动时替换 xdebug.so。

ETA (03/27/18):就我而言,我发现 v2.6.0 转义 XML 引号存在问题。这为我修复了它:
  "super_globals": false,

( https://github.com/martomo/SublimeTextXdebug/issues/172 )

预计到达时间 2018 年 10 月 24 日

后来我发现上面的修复并没有真正起作用;它只是在某些情况下避免了错误。就我而言,解决方案涉及 fork 软件包并应用补丁。 https://stackoverflow.com/a/49537268/318831

关于sublimetext3 - Xdebug 上下文没有显示任何内容并且浏览器一直在加载?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49204959/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com