[codeface] Re: Bugfixes and copyright header cleanups

  • From: Rodrigo Queiroz <rqueiroz@xxxxxxxxxxxxxxxx>
  • To: codeface@xxxxxxxxxxxxx
  • Date: Tue, 21 Jun 2016 15:20:31 -0400

Hi Wolfgang,

Thanks for the updates. I started using codeface just now for a new project
and
never had a fully working/tested build before to make a better analysis of
the updates.

Master Branch:
My first build was from the Master branch, using vagrant and virtualbox
(using R 3.2.5)
The package plyr causes this error at the cluster phase:
--

2016-06-15 23:55:39 [codeface.util] MainProcessINFO:   -> Revision range
v3.8..v3.9: Detecting clusters...
Error in unloadNamespace(package) :
  namespace 'plyr' is imported by 'ggplot2', 'scales', 'reshape' so cannot
be unloaded
Error in library(plyr) : Package 'plyr' version 1.8.3 cannot be unloaded
Calls: suppressPackageStartupMessages -> withCallingHandlers -> library
Execution halted

 --

For-Upstream Branch:
My second test was after your recent updates. It didn't work with
virtualbox and the Xenial box.
The "vagrant up" fails before even creating the shared directory.
--

default: /tmp/vagrant-shell: line 1: cd: /vagrant: No such file or
directory
==> default: /tmp/vagrant-shell: line 3:
integration-scripts/install_repositories.sh: No such file or directory
==> default: /tmp/vagrant-shell: line 4:
integration-scripts/install_common.sh: No such file or directory
==> default: /tmp/vagrant-shell: line 5:
integration-scripts/install_codeface_R.sh: No such file or directory
==> default: /tmp/vagrant-shell: line 6:
integration-scripts/install_codeface_node.sh: No such file or directory
==> default: /tmp/vagrant-shell: line 7:
integration-scripts/install_codeface_python.sh: No such file or directory
==> default: /tmp/vagrant-shell: line 9:
integration-scripts/install_cppstats.sh: No such file or directory
==> default: /tmp/vagrant-shell: line 11:
integration-scripts/setup_database.sh:

--

However, I changed to Ubuntu Trusty and it worked fine for me.
With this working build (for-upstream branch, but with trusty box), only
the feature tests from the integration fail.

--

======================================================================
ERROR: testEndToEnd
(integration.test_features.TestEndToEndOnlyTaggingExample3Feature)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/vagrant/codeface/test/integration/test_features.py", line 46, in
testEndToEnd
    self.checkEdges()
  File "/vagrant/codeface/test/integration/test_exampleprojects.py", line
147, in checkEdges
    cluster_id = dbm.get_cluster_id(project_id, release_range)
  File "/vagrant/codeface/dbmanager.py", line 156, in get_cluster_id
    raise Exception("Cluster from project {} not found!".format(pid))
Exception: Cluster from project 113 not found!

======================================================================
ERROR: testEndToEnd
(integration.test_features.TestEndToEndOnlyTaggingExample3Feature_File)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/vagrant/codeface/test/integration/test_features.py", line 46, in
testEndToEnd
    self.checkEdges()
  File "/vagrant/codeface/test/integration/test_exampleprojects.py", line
147, in checkEdges
    cluster_id = dbm.get_cluster_id(project_id, release_range)
  File "/vagrant/codeface/dbmanager.py", line 156, in get_cluster_id
    raise Exception("Cluster from project {} not found!".format(pid))
Exception: Cluster from project 115 not found!

----------------------------------------------------------------------

--


I also tried with a project and could confirm the analysis with "tagging:
file" works.
With "tagging: feature", the dependencies at feature level are not found
and the clusters phase fail:

2016-06-20 15:57:18 [codeface.util] MainProcess INFO:   -> Revision range
1_22_0..1_23_0: Detecting clusters...
/usr/bin/env: Rscript: No such file or directory
2016-06-20 15:57:18 [codeface.util] MainProcess ERROR: Command
'/vagrant/codeface/R/cluster/persons.r --loglevel info -c
/vagrant/codeface.conf -p /tmp/busyboxuFG__Y
/vagrant/results/busybox/feature/1_22_0-1_23_0 13' failed with exit code
127.
(stdout: None
stderr: None)
Traceback (most recent call last):
  File "/usr/local/bin/codeface", line 9, in <module>
    load_entry_point('codeface', 'console_scripts', 'codeface')()
  File "/vagrant/codeface/cli.py", line 202, in main
    return run(sys.argv)
  File "/vagrant/codeface/cli.py", line 198, in run
    return args.func(args)
  File "/vagrant/codeface/cli.py", line 117, in cmd_run
    args.profile_r, args.jobs, args.tagging, args.reuse_db)
  File "/vagrant/codeface/project.py", line 136, in project_analyse
    endmsg=prefix + "Detecting clusters done."
  File "/vagrant/codeface/util.py", line 110, in add
    func(*args, **kwargs)
  File "/vagrant/codeface/util.py", line 279, in execute_command
    raise Exception(msg)
Exception: Command '/vagrant/codeface/R/cluster/persons.r --loglevel info
-c /vagrant/codeface.conf -p /tmp/busyboxuFG__Y
/vagrant/results/busybox/feature/1_22_0-1_23_0 13' failed with exit code
127.
(stdout: None
stderr: None)



Do I need any additional configuration or dependencies to work with the
feature analysis?

Best,
Rodrigo



On Sun, Jun 19, 2016 at 5:39 PM, Wolfgang Mauerer <
wolfgang.mauerer@xxxxxxxxxxxxxxxxx> wrote:

Am 17/06/2016 um 16:16 schrieb Claus Hunsen:
thank you very much for this list of patches, Wolfgang. The error with
the plyr package appeared to me just yesterday and I was about to fix it
somehow, when I saw your patches.

Unfortunately, the Travis build on your pull request fails due to
further problems where R tries to unload packages.

Here the list of occurrences:
https://travis-ci.org/siemens/codeface/builds/138348511#L8019
https://travis-ci.org/siemens/codeface/builds/138348511#L8494
https://travis-ci.org/siemens/codeface/builds/138348511#L8769
https://travis-ci.org/siemens/codeface/builds/138348511#L9151
https://travis-ci.org/siemens/codeface/builds/138348511#L9507
The first occurrence is related to the "slam" package, the others to
"plyr".

... and after several more unpleasant encounters with outdated
software packages on an ancient base distribution, I decided to fix the
problem properly by lifting the base distribution to Ubuntu 16.04.
Results are in branch for-upstream, and things work (without
substantial testing, but deployment and VCS based project analysis are
fine) for vagrant-lxc. Did not do any testing with Virtualbox or other
VMs yet. Further testing and feedback are appreciated!

Until I figure out how travis-ci.org can be instructed to use a more
recent base distribution than Ubuntu 12.04 (hints welcome ;)),
continuous integration testing is broken for branch for-upstream.

Thanks, Wolfgang


@all: Does anyone know why this problems appears just now and not
earlier? Seems weird to me...

Best,
Claus


Am 16.06.2016 um 22:46 schrieb Wolfgang Mauerer:
The following series fixes some problems with upstream changes in
various packages, and makes vagrant based deployments more robust.
It also adds license information to previously implicitly licensed
files. All copyright holders are notified on CC for the respective
patches.

If nobody objects, I'll merge at the beginning of next week. The series
is also available in branch for-upstream.

--
 b/Vagrantfile                                    |    3
 b/codeface/R/cluster/persons.r                   |    2
 b/codeface/R/complexity.r                        |    2
 b/codeface/R/developer_classification.r          |   16 ++++
 b/codeface/R/test_developer_classification.r     |   16 ++++
 b/integration-scripts/install_codeface_R.sh      |    5 -
 b/integration-scripts/install_codeface_node.sh   |    2
 b/integration-scripts/install_codeface_python.sh |    2
 b/integration-scripts/install_common.sh          |    2
 b/integration-scripts/install_cppstats.sh        |   36 ++++++++--
 b/integration-scripts/setup_database.sh          |    3
 b/integration-scripts/test_codeface.sh           |    2
 b/packages.r                                     |   78
+++++++++++++++++++++++
 packages.R                                       |   59
-----------------
 packages.minimal.R                               |   10 --
 15 files changed, 157 insertions(+), 81 deletions(-)
From: Wolfgang Mauerer <wolfgang.mauerer@xxxxxxxxxxxxxxxxx>
Subject: Bugfixes and copyright header cleanups
In-Reply-To:







-- 
*Rodrigo Queiroz, M.Sc.*

*Ph.D. Student *
*Generative Software Development Lab*
*University of Waterloo*
*200 University Ave. West, *
*Waterloo, ON, N2L 3G1, **CANADA*

*Tel.: +1 519 885 1211 x35035*

*Mob:+1 226 606 2133*
*rodrigoqueiroz.skype*

Other related posts: