XDebug doesn't stop on breakpoints set on Yii controllers' actions - netbeans

I code in Yii framewor, using Netbeans 8.0.1 and also Eclipse. My local developement environment is build on XAMPP. I can see, that breakpoints set anywhere within Wordpress code works just fine. But, when I try to set a breakpoint on any Yii's controller or action, XDebug won't stop at that point. It only work on index.php of my project.
However, xdebug_break() work for controllers, but not actions.
My php.ini settings for XDebug are:
[XDebug]
zend_extension = C:\xampp\php\ext\php_xdebug-2.2.5-5.5-vc11.dll
;xdebug.profiler_append = 0
;xdebug.profiler_enable = 1
;xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "C:\xampp\tmp"
xdebug.profiler_output_name = "cachegrind.out.%t-%s"
xdebug.remote_enable = 1
xdebug.remote_handler = "dbgp"
xdebug.remote_host = 127.0.0.1
xdebug.trace_output_dir = "C:\xampp\tmp"
xdebug.idekey=netbeans-xdebug
xdebug.remote_port=9000
xdebug.remote_log = "c:/xampp/tmp/xdebug_remot.log"
xdebug.show_local_vars = 9
xdebug.max_nesting_level = 250
xdebug.auto_trace=1
xdebug.remote_server = 127.0.0.1
I'm trying to deal with this problem for about a week and still didn't come with any solution.

Related

Xdebug is running but not debugging on laragon

I have set up the Xdebug correctly and I can see it is running but does not debugging.
Also I have set up php.ini
[xdebug]
xdebug.remote_enable=1
xdebug_remote_autostart=1
;zend_extension=xdebug
zend_extension = "C:\laragon\bin\php\php-7.4.19-Win32-vc15-x64\ext\php_xdebug-3.0.4-7.4-vc15-x86_64.dll"
xdebug.remote_host = "http://127.0.0.1:8000/"
enter code here

Xcode 8.2: Unable to load configuration data from specified path / permission error in Mac OSX App:

I have a Mac OSX app that I have previously been able to test - however when I run tests now - it will work once and then fail with the error below in the console. I need to do some drastic things to get it working:
If I
change the location of my Derived Data folder
and clean build folder - then it will usually work again once or twice before but when I run tests again it will happen again.
Any ideas of what I can do to fix it permanently - below is pretty much Greek to me..
I have tried the following:
moving the derived data into Documents
installing new Xcode from Appstore.
Deleting and re-adding Certificates and profiles
2017-01-15 16:41:51.247064 XXXXXX[51736:892136] Unable to load
configuration data from specified path
/var/folders/59/7ylv57053bv3c0rbbcc1mcg40000gp/T/com.apple.dt.XCTest/FDF2A461-45D7-4E64-B650-602DF0725CA7/remote-container/tmp/XXXXXXTests-FDF2A461-45D7-4E64-B650-602DF0725CA7.xctestconfiguration;
error: You don’t have permission. 2017-01-15 16:41:51.247221
XXXXXX[51736:892136] IDEBundleInjection Arguments: (
"/Users/XXXXXX/XXXXXX/XXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug/XXXXXX.app/Contents/MacOS/XXXXXX",
"-NSTreatUnknownArgumentsAsOpen",
NO,
"-ApplePersistenceIgnoreState",
YES ) 2017-01-15 16:41:51.248336 XXXXXX[51736:892136] IDEBundleInjection Environment: {
"APP_SANDBOX_CONTAINER_ID" = "com.XXXXXX.XXXXXX";
"Apple_PubSub_Socket_Render" = "/private/tmp/com.apple.launchd.hKPiBBDAAG/Render";
"CFFIXED_USER_HOME" = "/Users/XXXXX/Library/Containers/com.XXXXXX.XXXXXX/Data";
"DTX_CONNECTION_SERVICES_PATH" = "/Applications/Xcode.app/Contents/SharedFrameworks/DTXConnectionServices.framework";
"DYLD_FRAMEWORK_PATH" = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug:/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug:/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks";
"DYLD_INSERT_LIBRARIES" = "";
"DYLD_LIBRARY_PATH" = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug:/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug:/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks";
HOME = "/Users/XXXXX/Library/Containers/com.grant.XXXXXX/Data";
LOGNAME = XXXXX;
MallocNanoZone = 1;
NSUnbufferedIO = YES;
"OS_ACTIVITY_DT_MODE" = YES;
PATH = "/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin";
PWD = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug";
SHELL = "/bin/bash";
"SSH_AUTH_SOCK" = "/private/tmp/com.apple.launchd.dNK7oacOAX/Listeners";
TMPDIR = "/var/folders/59/7ylv57053bv3c0rbbcc1mcg40000gp/T/com.grant.XXXXXX/";
USER = XXXXX;
XCInjectBundleInto = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug/XXXXXX.app/Contents/MacOS/XXXXXX";
"XCODE_DBG_XPC_EXCLUSIONS" = "com.apple.dt.xctestSymbolicator";
XCTestConfigurationFilePath = "/var/folders/59/7ylv57053bv3c0rbbcc1mcg40000gp/T/com.apple.dt.XCTest/FDF2A461-45D7-4E64-B650-602DF0725CA7/remote-container/tmp/XXXXXXTests-FDF2A461-45D7-4E64-B650-602DF0725CA7.xctestconfiguration";
"XPC_FLAGS" = 0x0;
"XPC_SERVICE_NAME" = "com.apple.dt.Xcode.23100";
"__CF_USER_TEXT_ENCODING" = "0x1F6:0x0:0x2";
"__XCODE_BUILT_PRODUCTS_DIR_PATHS" = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug";
"__XPC_DYLD_FRAMEWORK_PATH" = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug";
"__XPC_DYLD_LIBRARY_PATH" = "/Users/XXXXX/XXX/XXXXXXX/XXXXXX-eghnritsumpbbqgylbzrxqfximew/Build/Products/Debug";
}
In Xcode 9 I found a solution, that worked for me.
Go to Xcode > File > Project Settings... (or Workspace Settings...)
Select New Build System (Preview) as Build System under Shared Settings.
Make sure to select Use Shared Setting under Per-User Project Settings.
I too logged a bug with Apple. Experienced it on Xcode 9. However, I then played with it some more and found that by changing the Derived Data Folder to Custom and disabling code coverage in my Test config for my scheme, the error went away. It seems that some combination of these two caused the issue.
I have logged a bug with Apple as it appears that no one else is getting this error.
Edit: Elise has filed bug Apple #34737491, if you are experiencing it - then please raise a bug and reference that ticket so Apple can see how big the impact is.

Using multiple Subdomains on TYPO3 and RealUrl

I have TYPO3 (4.5) installed and a running project. The RealUrl extension is installed and enabled. Everything works as it should. For a proper user of the RealUrl extension i needed to add a few lines of code to the main template.
config.simulateStaticDocuments = 0
config.baseURL = http://www.example.com/
config.tx_realurl_enable = 1
Now i need access to the site by different sub-domains (eg "www1"). I tried the code below, but it is not working. I am not sure about the script i came up with.
host = example.com
[globalString = IENV:HTTP_HOST=www.example.com]
host = www.example.com
[globalString = IENV:HTTP_HOST=www1.example.com]
host = www1.example.com
[global]
config.simulateStaticDocuments = 0
config.baseURL= http://{$host}/
config.tx_realurl_enable = 1
Is this sufficient to keep the system running?
Variables need to be registered at the constant part of the template. TypoScript is no scripting language, but a treebuilding definition set.
I suggest to skip variables alltogether and instead append the following to the end of your TypoScript.
config.baseURL = http://example.com
[globalString = IENV:HTTP_HOST=www.example.com]
config.baseURL = http://www.example.com
[globalString = IENV:HTTP_HOST=www1.example.com]
config.baseURL = http://www1.example.com
[global]
Additionally you should use config.absRefPrefix instead of config.baseURL.

Setting output_style for SCSS using Compass in Sinatra app

I'm looking at the Compass-Sinatra starter file on GitHub. Is there a way to set the output_style for an scss file in Sinatra? Ideally I would like to set the style to :expanded when in development.
I think I'm having trouble understanding how sass(:"stylesheets/#{params[:name]}", Compass.sass_engine_options ) works and where I can set those options.
I found that adding the output_style setting to the compass.config file works for changing the output_style. It can either go in the if defined?(Sinatra) block or in the configuration block at the bottom of the compass.config file.
# compass-sinatra-starter/config/compass.config
if defined?(Sinatra)
# This is the configuration to use when running within sinatra
project_path = Sinatra::Application.root
environment = :development
output_style = :expanded # This is where you can set the output_style
else
# this is the configuration to use when running within the compass command line tool.
css_dir = File.join 'static', 'stylesheets'
relative_assets = true
environment = :production
end
# Or if you wanted to have the output_style set for all environments(?)
# This is common configuration
output_style = :compressed
sass_dir = File.join 'views', 'stylesheets'
images_dir = File.join 'static', 'images'
http_path = "/"
http_images_path = "/images"
http_stylesheets_path = "/stylesheets"
Note: stop/start the server if you change the settings if you don't see the change.
For example, I have a styles.scss file in views/stylesheets/styles.scss then if I go to http://localhost:4567/stylesheets/styles.css I'll get the .scss file compiled in the browser to .css. Changing the output_style, start/stop the server the .css output_style changes. I don't know if using reloader would work, but it might avoid the stop/start?
I found a couple of other good resources.
Andrew Stewart has a blog post and a GitHub template
Originally I was trying to learn about media queries in Sass(scss) with Sinatra and found a great video Ben Schwarz posted, but it doesn't go into the nitty gritty of setting up. It's more about the media query. Ben also has the source on GitHub.
But it seems like AssetPack is the best way to go for serving assets.

xdebug in xampp doesn't work on netbeans

I try to config xdebug but doesn't work I use:
XAMPP 1.7.4 , Netbeans 7.0
Xdebug installed: 2.1.0rc1
Server API: Apache 2.0 Handler
Windows: yes - Compiler: MS VC6 - Architecture: x86
Zend Server: no
PHP Version: 5.3.5
Zend API nr: 220090626
PHP API nr: 20090626
Debug Build: no
Thread Safe Build: yes
Configuration File Path: C:\WINDOWS
Configuration File: C:\xampp\php\php.ini
Extensions directory: C:\xampp\php\ext
And php.ini:
zend_extension = "C:\xampp\php\ext\php_xdebug.dll"
xdebug.collect_includes = 1
xdebug.collect_params = 1
xdebug.collect_return = 1
xdebug.default_enable = 1
xdebug.extended_info = 1
xdebug.profiler_append = 0
xdebug.profiler_enable = 1
xdebug.profiler_enable_trigger = 0
xdebug.profiler_output_dir = "C:\xampp\tmp"
xdebug.remote_autostart = 1
xdebug.remote_enable = 1
xdebug.remote_handler = "DBGp"
xdebug.remote_host = "localhost"
xdebug.remote_port = 9000
Now the problems:
Menu attach Debugger is still disabled or grayed out.
When I try to debug the break point is never hit. Scripts run like a normal.
Following is the URL of I get when I click Debug main project:
http://localhost/index.php?XDEBUG_SESSION_START=netbeans-xdebug
When I close the browser debugger does not stop. It shows the waiting for connection status.
When I click the stop debugging button in NetBeans gives a messagebox There is no connection from xdebug detected with in some seconds xdebug is not configured or xdebug is not installed.
Please guide me to resolve the above mentioned issues and debug the project.
First are you able to see xdebug in http://localhost/xampp/index.php ? If NOT then probably you are NOT editing the right php.ini file? Seems like XAMPP is using the php.ini file in:
c:\xampp\apache\bin\php.ini
Enter your configuration for xdebug in that file, restart Apache and you should be able to connect.
There was no need for me to change anything in Netbeans to get it to work.
Screenshots here: http://rudyegenias.wordpress.com/2011/07/03/xampp-xdebug-xdebug-not-showing-in-phpinfo/
? to use XDebug on Netbeans & XAMPP
use http://xdebug.org/wizard.php to inspect your system and download best xdebug.dll
place that .dll in C:/xampp/php/ext
edit C:/xampp/php/php.ini adding following
[XDebug]
zend_extension = C:\xampp\php\ext\php_xdebug-2.2.3-5.5-vc11.dll
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.show_local_vars=on
xdebug.output_buffering=off
restart Apache web server
I've struggled with a lot of other setting but this is best to do the job