View Issue Details

IDProjectCategoryView StatusLast Update
0002055XdebugStep Debuggingpublic2022-05-16 16:21
Reporterlaurin1 Assigned Toderick  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Product Version3.1.2 
Target Version3.1devFixed in Version3.1.3 
Summary0002055: Debugger creates XML with double facet attribute
Description

I'm not sure if this is an Xdebug issue or PHPStorm issue (I'm not experienced with debugging using any other tools), I will be submitting the bug report to JetBrains as well. Step debugging using these 2 has worked great for years. However, I'm suddenly having issues with certain breakpoints not working. The IDE stops on the breakpoint briefly, like for half a second, then immediately proceeds through the rest of the code. The classes that seem to be affected are MySQL related, thought that might just be circumstantial.

[22108] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug&quot; command="context_get" transaction_id="16" status="break" reason="ok"><xdebug:message filename="file:///C:/inetpub/Intranet_Local/library/Intranet/DB/MySQLiIntranet.php" lineno="222"></xdebug:message></response>

[22108] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug&quot; status="stopping" reason="ok"></response>

[22108] [Step Debug] WARN: 2021-12-22 20:13:32.087622: There was a problem sending 179 bytes on socket 608: An established connection was aborted by the software in your host machine.

Steps To Reproduce

Going to be very difficult to create steps to reproduce that are isolated as this is a huge project.

Additional Information

I have logs from both PHPStorm and Xdebug that can attach, but contain sensitive data (a lot of it, too hard to strip it all and be certain it's clean).

TagsNo tags attached.
Operating SystemWindows 10 x64 21H1
PHP Version7.4.20-7.4.29

Relationships

has duplicate 0002094 resolvedderick Public static property with closure data type have double facet XML attribute 

Activities

laurin1

2021-12-22 20:15

reporter   ~0006178

I've verified the issue occurs with 3.1.1 as well.

laurin1

2021-12-22 20:22

reporter   ~0006179

C:\windows\system32>php -v
PHP 7.4.26 (cli) (built: Nov 17 2021 10:35:45) ( NTS Visual C++ 2017 x64 )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies

laurin1

2021-12-22 20:27

reporter   ~0006180

Looks like it might be a PHPStorm issue:

2021-12-22 14:12:19,865 [94306276] INFO - il.connection.ServerConnection - Stopped listening on port 9003
2021-12-22 14:12:20,435 [94306846] WARN - php.debug.xdebug.dbgp.DbgpUtil - Could not parse packet
org.jdom.JDOMException: Duplicate attributes "facet" (index 3), "facet" (index 9)
at [row,col {unknown-source}]: [2,5130]
at com.intellij.openapi.util.JDOMUtil.load(JDOMUtil.java:318)
at com.intellij.openapi.util.JDOMUtil.load(JDOMUtil.java:244)
at com.jetbrains.php.debug.xdebug.dbgp.DbgpUtil.parseDocument(DbgpUtil.java:196)
at com.jetbrains.php.debug.xdebug.dbgp.DbgpUtil.getDocument(DbgpUtil.java:168)
at com.jetbrains.php.debug.xdebug.dbgp.DbgpUtil.readDocument(DbgpUtil.java:144)
at com.jetbrains.php.debug.xdebug.dbgp.DbgpUtil.readMessage(DbgpUtil.java:302)
at com.jetbrains.php.debug.xdebug.connection.XdebugConnection$MyInputReader.read(XdebugConnection.java:149)
at com.jetbrains.php.debug.xdebug.connection.XdebugConnection$MyInputReader.read(XdebugConnection.java:138)
at com.jetbrains.php.debug.connection.PhpDebugConnection.lambda$startReading$2(PhpDebugConnection.java:291)
at com.intellij.openapi.application.impl.ApplicationImpl$1.run(ApplicationImpl.java:263)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: com.fasterxml.aalto.WFCException: Duplicate attributes "facet" (index 3), "facet" (index 9)
at [row,col {unknown-source}]: [2,5130]
at com.fasterxml.aalto.in.XmlScanner.reportInputProblem(XmlScanner.java:1333)
at com.fasterxml.aalto.in.ReaderScanner.handleStartElement(ReaderScanner.java:802)
at com.fasterxml.aalto.in.ReaderScanner.nextFromTree(ReaderScanner.java:297)
at com.fasterxml.aalto.stax.StreamReaderImpl.next(StreamReaderImpl.java:760)
at com.intellij.openapi.util.SafeStAXStreamBuilder.processElementFragment(SafeStAXStreamBuilder.java:124)
at com.intellij.openapi.util.SafeStAXStreamBuilder.build(SafeStAXStreamBuilder.java:94)
at com.intellij.openapi.util.JDOMUtil.load(JDOMUtil.java:311)

derick

2021-12-22 21:47

administrator   ~0006181

This looks like xdebug is setting two facets on one attribute which it shouldn't do. Can you find I'm your log the line that has two facet attributes in the same xml element. It's likely just before the end of the Xdebug log.

laurin1

2021-12-22 22:50

reporter   ~0006183

I set the previous note as private, probably not necessary, but just being cautious. Can you see it?

derick

2021-12-22 23:08

administrator   ~0006184

Yes, I can read it, and see where the problem is. Going to have a proper look tomorrow.

derick

2021-12-23 11:16

administrator   ~0006185

Fixed through https://github.com/xdebug/xdebug/pull/814 for 3.1.3.

laurin1

2021-12-23 16:48

reporter   ~0006186

You are awesome! Do you know the timeframe for this release? Is there a nightly build I can pull?

Issue History

Date Modified Username Field Change
2021-12-22 20:14 laurin1 New Issue
2021-12-22 20:15 laurin1 Note Added: 0006178
2021-12-22 20:22 laurin1 Note Added: 0006179
2021-12-22 20:27 laurin1 Note Added: 0006180
2021-12-22 21:47 derick Assigned To => derick
2021-12-22 21:47 derick Status new => feedback
2021-12-22 21:47 derick Note Added: 0006181
2021-12-22 22:50 laurin1 Status feedback => assigned
2021-12-22 22:50 laurin1 Note Added: 0006183
2021-12-22 23:08 derick Note Added: 0006184
2021-12-23 10:29 derick Summary Certain breakpoints caused Xdebug used with PHPStorm to exit and not break anymore => Debugger creates XML with double facet attribute
2021-12-23 10:30 derick Target Version => 3.1dev
2021-12-23 11:16 derick Status assigned => closed
2021-12-23 11:16 derick Resolution open => fixed
2021-12-23 11:16 derick Fixed in Version => 3.1dev
2021-12-23 11:16 derick Note Added: 0006185
2021-12-23 16:48 laurin1 Note Added: 0006186
2022-02-01 16:27 derick Fixed in Version 3.1dev => 3.1.3
2022-05-16 16:21 derick Relationship added has duplicate 0002094