Menu

#54 PHP Notice: Undefined offset: 0 in /opt/bettech/tools/static_analysis/PhpCheckstyle/src/Tokenizer.php on line 128

Fixed
nobody
None
Medium
Defect
2013-09-20
2013-09-19
Anonymous
No

Originally created by: DSBerli...@gmail.com

What steps will reproduce the problem?
1. I am running it through Ant, I have included the command below
2.
3.

What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?
Version 0.12.2
Centos 6.4

Please provide any additional information below.

php /opt/bettech/tools/static_analysis/PhpCheckstyle//run.php --src /opt/bettech --format xml --config default.cfg.xml --outdir /opt/bettech/tools/build --exclude documentation/ --exclude lib/ --exclude scripts/ --exclude tools/ --exclude test --exclude var/  --exclude modules/

Related

Wiki: History

Discussion

  • Anonymous

    Anonymous - 2013-09-19

    Originally posted by: DSBerli...@gmail.com

    Sorry forgot to add the full stack trace:

    [exec] PHP Notice:  Undefined offset: 0 in /opt/bettech/tools/static_analysis/PhpCheckstyle/src/Tokenizer.php on line 128
         [exec] PHP Stack trace:
         [exec] PHP   1. {main}() /opt/bettech/tools/static_analysis/PhpCheckstyle/run.php:0
         [exec] PHP   2. PHPCheckstyle->processFiles() /opt/bettech/tools/static_analysis/PhpCheckstyle/run.php:113
         [exec] PHP   3. PHPCheckstyle->_processFile() /opt/bettech/tools/static_analysis/PhpCheckstyle/src/PHPCheckstyle.php:295
         [exec] PHP   4. Tokenizer->getCurrentToken() /opt/bettech/tools/static_analysis/PhpCheckstyle/src/PHPCheckstyle.php:419
         [exec] PHP Fatal error:  Call to a member function getName() on a non-object in /opt/bettech/tools/static_analysis/PhpCheckstyle/src/PHPCheckstyle.php on line 558
         [exec] PHP Stack trace:
         [exec] PHP   1. {main}() /opt/bettech/tools/static_analysis/PhpCheckstyle/run.php:0
         [exec] PHP   2. PHPCheckstyle->processFiles() /opt/bettech/tools/static_analysis/PhpCheckstyle/run.php:113
         [exec] PHP   3. PHPCheckstyle->_processFile() /opt/bettech/tools/static_analysis/PhpCheckstyle/src/PHPCheckstyle.php:295
         [exec] PHP   4. PHPCheckstyle->_processToken() /opt/bettech/tools/static_analysis/PhpCheckstyle/src/PHPCheckstyle.php:425
         [exec] Result: 255

     
  • Anonymous

    Anonymous - 2013-09-19

    Originally posted by: tch...@hotmail.com

    I will have a look a soon as I can (probably tomorrow).

    What would help me is to have an extract of the code that produce the error.
    The "--progress" option should help indicate what file is generating the problem. If you have no problem to share you code you can send it to me.

    Thanks,

    Status: Accepted

     
  • Anonymous

    Anonymous - 2013-09-20

    Originally posted by: DSBerli...@gmail.com

    The --progress flag helped a lot, turns out I have an empty PHP file in my project.

     
  • Anonymous

    Anonymous - 2013-09-20

    Originally posted by: tch...@hotmail.com

    OK, cool.

    I will try to correct it anyway.

    Thanks

     
  • Anonymous

    Anonymous - 2013-09-20

    Originally posted by: tch...@hotmail.com

    (No comment was entered for this change.)

    Status: Fixed

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.