Zend Framework

Update all docblocks to use consistent copyright/license header.

Details

  • Type: Coding Standards Violation Coding Standards Violation
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.0.1
  • Fix Version/s: 1.8.4
  • Component/s: None
  • Labels:
    None

Description

There are quite a few code files throughout the library, tests, and incubator that have an inconsistent header docblock.

We need to have a single canonical header docblock that correctly describes the copyright and license for the code, and we need to make that docblock present in all files for PHP code, tests, scripts, etc.

Issue Links

Activity

Hide
Bill Karwin added a comment -

Changing fix version to unknown.

Show
Bill Karwin added a comment - Changing fix version to unknown.
Hide
Ralph Schindler added a comment -

We should aim to document this task at this location:

http://framework.zend.com/wiki/display/ZFDEV/PHP+Coding+Standard+%28draft%2C+ZF+0.2+RC1%29#PHPCodingStandard%28draft%2CZF0.2RC1%29-InlineDocumentation

This should be stock, for copy and paste with minimal substitutions.., also year should be updated to 2007

Show
Ralph Schindler added a comment - We should aim to document this task at this location: http://framework.zend.com/wiki/display/ZFDEV/PHP+Coding+Standard+%28draft%2C+ZF+0.2+RC1%29#PHPCodingStandard%28draft%2CZF0.2RC1%29-InlineDocumentation This should be stock, for copy and paste with minimal substitutions.., also year should be updated to 2007
Hide
Raphael Geissert added a comment -

More information:

The file ZendFramework-1.0.1/library/Zend/Db/Adapter/Db2.php contains
the next copyright line:

Where it should be like the others:

  • @copyright Copyright (c) 2005-2007 Zend Technologies USA, Inc

Similar to * @copyright 2005 Zend Technologies in file
/ZendFramework-1.0.1/demos/Zend/Gdata/Blogger.php

And it would be much better if files with different copyrights aren't
shipped. These include the xml samples located at
ZendFramework-1.0.1/tests/Zend/Feed/_files/, parts of the PEAR manual
located at ZendFramework-1.0.1/tests/Zend/Search/Lucene/_files/_indexSource
and ZendFramework-1.0.1/demos/Zend/Search/Lucene/indexing/IndexSource/

Using grep[1] you will find more of those files not covered by the
copyright information in LICENSE.txt

[1] grep -ir copyright ZendFramework-1.0.1 | grep -vi "Zend Technologies USA"

Show
Raphael Geissert added a comment - More information: The file ZendFramework-1.0.1/library/Zend/Db/Adapter/Db2.php contains the next copyright line: Where it should be like the others:
  • @copyright Copyright (c) 2005-2007 Zend Technologies USA, Inc
Similar to * @copyright 2005 Zend Technologies in file /ZendFramework-1.0.1/demos/Zend/Gdata/Blogger.php And it would be much better if files with different copyrights aren't shipped. These include the xml samples located at ZendFramework-1.0.1/tests/Zend/Feed/_files/, parts of the PEAR manual located at ZendFramework-1.0.1/tests/Zend/Search/Lucene/_files/_indexSource and ZendFramework-1.0.1/demos/Zend/Search/Lucene/indexing/IndexSource/ Using grep[1] you will find more of those files not covered by the copyright information in LICENSE.txt [1] grep -ir copyright ZendFramework-1.0.1 | grep -vi "Zend Technologies USA"
Hide
Ralph Schindler added a comment -
  • smarter @package / @subpackage docblock items for better apidoc building
  • consistent require_once docblock
  • link to bug tracker (jira) so that its easy to know where to report bugs

-more to come

Show
Ralph Schindler added a comment -
  • smarter @package / @subpackage docblock items for better apidoc building
  • consistent require_once docblock
  • link to bug tracker (jira) so that its easy to know where to report bugs
-more to come
Hide
Darby Felton added a comment -

Affects version 1.0.1 (and prior).

Show
Darby Felton added a comment - Affects version 1.0.1 (and prior).
Hide
Darby Felton added a comment -

Fixed @license tags in PHP files with SVN r6398.

Show
Darby Felton added a comment - Fixed @license tags in PHP files with SVN r6398.
Hide
Darby Felton added a comment -

Replaced references to old license location with current license location with SVN r6400.

Show
Darby Felton added a comment - Replaced references to old license location with current license location with SVN r6400.
Hide
Darby Felton added a comment -

Replaced references to LICENSE with current filename LICENSE.txt with SVN r6401.

Show
Darby Felton added a comment - Replaced references to LICENSE with current filename LICENSE.txt with SVN r6401.
Hide
Wil Sinclair added a comment -

This issue should have been fixed for the 1.5 release.

Show
Wil Sinclair added a comment - This issue should have been fixed for the 1.5 release.
Hide
Wil Sinclair added a comment -

This doesn't appear to have been fixed in 1.5.0. Please update if this is not correct.

Show
Wil Sinclair added a comment - This doesn't appear to have been fixed in 1.5.0. Please update if this is not correct.
Hide
Wil Sinclair added a comment -

Haven't you been working on this, Thomas? If so, please close when finished. If not, please feel free to unassign it from yourself.

Show
Wil Sinclair added a comment - Haven't you been working on this, Thomas? If so, please close when finished. If not, please feel free to unassign it from yourself.
Hide
Thomas Weidner added a comment -

The file- and the classheader are checked within our new CodingStandard.

If it does not fit 100% a error will be thrown when checking for CS conformity.
BUT: Actually more than 200.000 other errors are thrown and the testbed is not 100% finished.

Therefor I will hold this issue opened until the new CodingStandard has been accepted and is official.

Show
Thomas Weidner added a comment - The file- and the classheader are checked within our new CodingStandard. If it does not fit 100% a error will be thrown when checking for CS conformity. BUT: Actually more than 200.000 other errors are thrown and the testbed is not 100% finished. Therefor I will hold this issue opened until the new CodingStandard has been accepted and is official.
Hide
Thomas Weidner added a comment -

Docblocks have been updated.

Coding standard now checks and throws error if they are wrong.

Show
Thomas Weidner added a comment - Docblocks have been updated. Coding standard now checks and throws error if they are wrong.
Hide
Wil Sinclair added a comment -

Updating to comply with new IT component conventions.

Show
Wil Sinclair added a comment - Updating to comply with new IT component conventions.
Hide
Wil Sinclair added a comment -

Updating for the 1.6.0 release.

Show
Wil Sinclair added a comment - Updating for the 1.6.0 release.
Hide
Bill Karwin added a comment -

Reopening issue because there are still many discrepancies in the @copyright and @license headers. I will post some grep commands to find nonstandard or missing headers.

Show
Bill Karwin added a comment - Reopening issue because there are still many discrepancies in the @copyright and @license headers. I will post some grep commands to find nonstandard or missing headers.
Hide
Thomas Weidner added a comment -

Assigned to Bill as he reopened the issue and wants to work on it again.

Note:
We will always have files which do not conform with their header. As long as we have no CI and this is not tested there is no way to have it 100% fixed as you would have to check after each commit or before each release.

Show
Thomas Weidner added a comment - Assigned to Bill as he reopened the issue and wants to work on it again. Note: We will always have files which do not conform with their header. As long as we have no CI and this is not tested there is no way to have it 100% fixed as you would have to check after each commit or before each release.
Hide
Bill Karwin added a comment -

Here is a command to find all @copyright headers, and count how many occur in each form:

egrep -r --include=\*.php -h '@copyright' library | sort | uniq -c | sort -nr | cat -v

Here is the result:

3033  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
 155  * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
  46  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc.
  39  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)^M
  15  * @copyright  Copyright (c) 22005-2009 Zend Technologies USA Inc. (http://www.zend.com)
  10  * @copyright  Copyright (C) 2008 - Present, Zend Technologies, Inc.
   8  * @copyright  Copyright (c) 2006 Zend Technologies USA Inc. (http://www.zend.com)
   7  * @copyright  Copyright (c) 2009 Zend Technologies USA Inc. (http://www.zend.com)^M
   7  * @copyright    Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
   4  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com/)
   4  * @copyright  Copyright (c) 2005-2009 Zend Technologies Inc. (http://www.zend.com)
   4  * @copyright  Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
   3  * @copyright  Copyright (c) 2005-2008, Zend Technologies USA Inc. (http://www.zend.com)
   2  * @copyright  Copyright (c) 2009 Zend Technologies USA Inc. (http://www.zend.com)
   2  * @copyright  Copyright (c) 2008 Zend Technologies USA Inc. (http://www.zend.com)
   1  * @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
   1  * @copyright  Copyright (c) 2009, Zend Technologies USA Inc. (http://www.zend.com)
   1  * @copyright  Copyright (C) 2007 - Present, Zend Technologies, Inc.

Likewise, replacing @copyright with @license in the previous search finds these distinct forms of the @license header:

3124  * @license    http://framework.zend.com/license/new-bsd     New BSD License
 156  * @license   http://framework.zend.com/license/new-bsd     New BSD License
  46  * @license    http://framework.zend.com/license/new-bsd     New BSD License^M
  16  * @license    New BSD {@link http://framework.zend.com/license/new-bsd}

Here is a command to find all files missing a @copyright header:

egrep -r --include=\*.php -L '@copyright' library

Here is the result (these same files are also missing the @license header):

library/Zend/Tool/Framework/Client/Console/ResponseDecorator/Colorizer.php
library/Zend/Tool/Framework/Client/Interactive/InputHandler.php
library/Zend/Tool/Framework/Client/Interactive/InputInterface.php
library/Zend/Tool/Framework/Client/Interactive/InputRequest.php
library/Zend/Tool/Framework/Client/Interactive/InputResponse.php
library/Zend/Tool/Framework/Client/Interactive/OutputInterface.php
library/Zend/Tool/Framework/Client/Response/ContentDecorator/Interface.php
library/Zend/Tool/Framework/Manifest/Interface.php
library/Zend/Tool/Framework/Provider/DocblockManifestable.php
library/Zend/Tool/Framework/Provider/Interactable.php
library/Zend/Tool/Framework/Registry/Exception.php
library/Zend/Tool/Framework/Registry/Interface.php
library/Zend/Tool/Framework/System/Provider/Phpinfo.php
library/Zend/Tool/Framework/System/Provider/Version.php
library/Zend/Tool/Project/Context/Exception.php
library/Zend/Tool/Project/Context/Interface.php
library/Zend/Tool/Project/Context/Repository.php

This result is based on revision 16450, in the ZF trunk.

Show
Bill Karwin added a comment - Here is a command to find all @copyright headers, and count how many occur in each form:
egrep -r --include=\*.php -h '@copyright' library | sort | uniq -c | sort -nr | cat -v
Here is the result:
3033  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
 155  * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
  46  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc.
  39  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)^M
  15  * @copyright  Copyright (c) 22005-2009 Zend Technologies USA Inc. (http://www.zend.com)
  10  * @copyright  Copyright (C) 2008 - Present, Zend Technologies, Inc.
   8  * @copyright  Copyright (c) 2006 Zend Technologies USA Inc. (http://www.zend.com)
   7  * @copyright  Copyright (c) 2009 Zend Technologies USA Inc. (http://www.zend.com)^M
   7  * @copyright    Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
   4  * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com/)
   4  * @copyright  Copyright (c) 2005-2009 Zend Technologies Inc. (http://www.zend.com)
   4  * @copyright  Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
   3  * @copyright  Copyright (c) 2005-2008, Zend Technologies USA Inc. (http://www.zend.com)
   2  * @copyright  Copyright (c) 2009 Zend Technologies USA Inc. (http://www.zend.com)
   2  * @copyright  Copyright (c) 2008 Zend Technologies USA Inc. (http://www.zend.com)
   1  * @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
   1  * @copyright  Copyright (c) 2009, Zend Technologies USA Inc. (http://www.zend.com)
   1  * @copyright  Copyright (C) 2007 - Present, Zend Technologies, Inc.
Likewise, replacing @copyright with @license in the previous search finds these distinct forms of the @license header:
3124  * @license    http://framework.zend.com/license/new-bsd     New BSD License
 156  * @license   http://framework.zend.com/license/new-bsd     New BSD License
  46  * @license    http://framework.zend.com/license/new-bsd     New BSD License^M
  16  * @license    New BSD {@link http://framework.zend.com/license/new-bsd}
Here is a command to find all files missing a @copyright header:
egrep -r --include=\*.php -L '@copyright' library
Here is the result (these same files are also missing the @license header):
library/Zend/Tool/Framework/Client/Console/ResponseDecorator/Colorizer.php
library/Zend/Tool/Framework/Client/Interactive/InputHandler.php
library/Zend/Tool/Framework/Client/Interactive/InputInterface.php
library/Zend/Tool/Framework/Client/Interactive/InputRequest.php
library/Zend/Tool/Framework/Client/Interactive/InputResponse.php
library/Zend/Tool/Framework/Client/Interactive/OutputInterface.php
library/Zend/Tool/Framework/Client/Response/ContentDecorator/Interface.php
library/Zend/Tool/Framework/Manifest/Interface.php
library/Zend/Tool/Framework/Provider/DocblockManifestable.php
library/Zend/Tool/Framework/Provider/Interactable.php
library/Zend/Tool/Framework/Registry/Exception.php
library/Zend/Tool/Framework/Registry/Interface.php
library/Zend/Tool/Framework/System/Provider/Phpinfo.php
library/Zend/Tool/Framework/System/Provider/Version.php
library/Zend/Tool/Project/Context/Exception.php
library/Zend/Tool/Project/Context/Interface.php
library/Zend/Tool/Project/Context/Repository.php
This result is based on revision 16450, in the ZF trunk.
Hide
Bill Karwin added a comment -

Fixed in revision 16541, which may have made it into the 1.8.4pl1 release.

Show
Bill Karwin added a comment - Fixed in revision 16541, which may have made it into the 1.8.4pl1 release.

People

Vote (0)
Watch (2)

Dates

  • Created:
    Updated:
    Resolved:

Time Tracking

Estimated:
1d
Original Estimate - 1 day
Remaining:
1d
Remaining Estimate - 1 day
Logged:
Not Specified
Time Spent - Not Specified