Scan python git history to find the function(s) definition(s) and their changes. Do changes relate to the type of passing parameters?
Find a file
Giuliano Antoniol d5bb16be2f added bounds
2025-06-13 17:17:05 -04:00
.idea update 2023-01-11 18:15:18 -05:00
src added bounds 2025-06-13 17:17:05 -04:00
tests forced update 2023-01-12 16:53:57 -05:00
venv update 2023-01-11 18:15:18 -05:00
.gitignore firced update 2023-01-11 12:41:32 -05:00
.gitmodules updated for emse ex tosem review 2025-03-24 10:46:19 -04:00
LICENSE baseline 2023-01-04 15:33:24 -05:00
pyproject.toml baseline 2023-01-04 15:33:24 -05:00
README.md updated README for modules processing 2023-01-12 17:41:56 -05:00

scan4func

Translate Python git commit history into a json reduced format representing functions/methods signature parameter evolution to study defects due to different parameter passing styles.

install

Remember you need the 3 modules utils, symtab and diff

BE AWARE

AVOID HTTPS and USE SSH be sure bothmachines are ssh-key authenticated on te git server

git submodule add git@gitlab.mazarol-gate.org:antoniol/utils.git src/utils

git submodule add git@gitlab.mazarol-gate.org:antoniol/package-symtab.git src/symtab

git submodule add git@gitlab.mazarol-gate.org:antoniol/diff_tools.git src/diff_tools

IF REALLY YOU USE HTTPS

git submodule add https://gitlab.mazarol-gate.org/antoniol/utils.git src/utils

git submodule add https://gitlab.mazarol-gate.org/antoniol/package-symtab.git src/symtab

git submodule add https://gitlab.mazarol-gate.org/antoniol/diff_tools.git src/diff_tools

the you must enter username and password by hand on the server when installing modules !

BE AWARE

Mayb be it is juts gitlab BUT in order to propagate changes to modules you MUST do a two steps commit:

  1. first commit the change e to the module and push it on the server; and then

  2. move a step up in the directory structure (say into py2json/src) and then to a commit and push of the directory alias module.

Remember, project root hosts the .gitmodules !!!! Consider the scenario:

  1. cloned py2jsel as usual with git clone

  2. updated modules i.e. for the project root run:

git submodule update --init --recursive

  1. you perform a change on one sub-module, say the file selector.py was modifier inside

py2jsel/src/symtab/src/

to propagate the change to the module git repository you MUST

  1. commit and push the change in the symtab directory (the module) ; then

  2. inside py2jsel or py2jsel/src commit and push the change to py2jsel/src/symtab

SUB-MODULES

Whe we do a submodule checkout it creates a detached head , do not panic, it is normal. You cab work in the detached head and then switch to the main master branch or attach the head. To do this to all modules go into the top directory and do:

git submodule update git submodule foreach git checkout master git submodule foreach git pull origin master

REMEMBER !

You must do a double commit if you work with modules and you must have the head attaches.

Suppose you modified a fine into my_mod

cd my_mod

git commit -am "my nice commit"

git push

cd into_top_level

git commit -am "force module to propagate" git push

======================

Alternatively do a per-module work

to all modules

If you end up with detached head:

  1. make a copy of you local work

  2. go into the sub-module and do a

git submodule update --remote --merge

  1. go in te top module rebuild the status with the master branch

git submodule update git submodule foreach git checkout master git submodule foreach git pull origin master

  1. copy bach your modules work (modified files)

4.1) go into module directory do a

git status

4.2) much likely status is different thus do a

git commit -am "force update" git push

commit all changed files into the module

4.3) go into the top module and commit the new branch status

git commit -am "force update" git push

REF:

https://www.atlassian.com/git/tutorials/git-submoduleŧ

https://git-scm.com/book/en/v2/Git-Tools-Submodules

https://stackoverflow.com/questions/3965676/why-did-my-git-repo-enter-a-detached-head-state