Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix "known" Windows errored test cases #525

Open
ankostis opened this issue Oct 3, 2016 · 1 comment
Open

Fix "known" Windows errored test cases #525

ankostis opened this issue Oct 3, 2016 · 1 comment

Comments

@ankostis
Copy link
Contributor

ankostis commented Oct 3, 2016

Currently, Windows TestCases on Appveyor established on #519 are "artifically" ok.
Because in the code, the Test Cases known to fail on have been marked with the HIDE_WINDOWS_KNOWN_ERRORS variable so that we get an ALL GREEN response; that way we can detect when new commits break additional TCs on Windows.

Currently there are 10 failing TCs (search them with the above var-name), and you can view the errors in this Appveyor job:

https://ci.appveyor.com/project/ankostis/gitpython/build/1.0.196

The errors are mostly related to 2 issues:

  1. Unicode: for those with reading time, I would suggest these 2 contradictory sources:
  2. Leaked resources: these are (possibly memmory-mapped) files that are not deallocated (and hence, not deleted afterwards). Unfortunately, dealing with them might mean that you have to jump projects, as some are inherited from the library projects smmp and (mostly) gitdb.

In order to reproduce the failed TCs on your PC, change locally git/test/lib/helper.py:#L38 from this:

    HIDE_WINDOWS_KNOWN_ERRORS = os.environ.get('HIDE_WINDOWS_KNOWN_ERRORS', True)

into this:

    HIDE_WINDOWS_KNOWN_ERRORS = os.environ.get('HIDE_WINDOWS_KNOWN_ERRORS', False)

This issue is about not forgetting these TCs - asking for help to fix them.

ankostis added a commit to ankostis/GitPython that referenced this issue Oct 4, 2016
+ Parse all config-urls \-->/.
+ Used relative daemon-paths.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() freezes now! (hidden win_err)
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 4, 2016
+ Parse all config-urls \-->/.
+ Used relative daemon-paths.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() freezes now! (hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 4, 2016
+ Parse all config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() freezes now! (hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
@Byron
Copy link
Member

Byron commented Oct 9, 2016

@ankostis Even though I won't be of much help here, I have just provided you with full write permissions on all the gitpython repositories that matter. Previously, I believe you might have been missing write access to smmap, for no other reason than me having forgotten to set it up right away :).

ankostis added a commit to ankostis/GitPython that referenced this issue Oct 11, 2016
+ Parse all config-urls \-->/.
+ Used relative daemon-paths.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() freezes now! (hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ Parse all config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() now freezes! (so still hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ Parse all config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() now freezes! (so still hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ Parse most remote & config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() now freezes! (so still hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
+ util: delete unused `absolute_project_path()`.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ Parse most remote & config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() now freezes! (so still hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
+ util: delete unused `absolute_project_path()`.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ FIXED also `TestSubmodule.test_root_module()`!
ankostis added a commit that referenced this issue Oct 12, 2016
+ FIXED also `TestSubmodule.test_root_module()`!
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ Parse most remote & config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() now freezes! (so still hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
+ util: delete unused `absolute_project_path()`.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ cmd: use DEVNULL for non PIPEs; no open-file.
+ TCs: some unitestize-assertions on base & remote TCs.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ cmd: use DEVNULL for non PIPEs; no open-file.
+ TCs: some unitestize-assertions on base & remote TCs.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
+ Parse most remote & config-urls \-->/.
+ Used relative daemon-paths.
+ Use git-daemon PORT above 10k; on Windows all below need Admin rights.
+FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
  + test_remote.test_base() now freezes! (so still hidden win_err)

+ repo_test: minor finally delete test-repos created inside this repo.
+ util: delete unused `absolute_project_path()`.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 12, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 13, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
+ Rework git-daemon launching with `with` resource-management.
+ cmd: add `is_cygwin` optional override kwd on `Git.polish_url()`.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
- Cygwin TCs failing (start, no Cygwin specific code):
  - PY2: err: 44, fail: 0
  - PY3: err: 13, fail: 0
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
+ Make `Git.polish_url()` convert paths into Cygwin-friendly paths.
+ Add utility and soe TCs for funcs for detecting cygwin and converting
abs-paths to `/cygdrive/c/...`.
- Cygwin TCs failing:
  - PY2: err: 14, fail: 3
  - PY3: err: 13, fail: 3
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
+ Rework git-daemon launching with `with` resource-management.
+ cmd: add `is_cygwin` optional override kwd on `Git.polish_url()`.
- Cygwin TCs failing:
  - PY2: err: 13, fail: 3
  - PY3: err: 12, fail: 3
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
- Cygwin TCs failing:
  - PY2: err: 13, fail: 3
  - PY3: err: 12, fail: 3
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
…init

- Cygwin TCs failing:
  - PY2: err: 13, fail: 2
  - PY3: err: 12, fail: 2
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
+ Bug discovered after enabling TC in prev commit and rework of fetch.
+ remote_tc: unitestize assertions.
+ util: DEL unused `_mktemp()`.
ankostis added a commit to ankostis/GitPython that referenced this issue Oct 14, 2016
…ions

+ Ignore `with_extended_output` arg when reaising the exception, keep
its behavior when `status==0`.
ankostis added a commit that referenced this issue Oct 14, 2016
+ git-daemon:
  + Use git-daemon PORT above 10k; on Windows all below need Admin rights.
  + Used relative daemon-paths with `--base-pth`.
  + Simplify git-daemon start/stop/ex-hanlding.
  +FIXED git-daemon  @with_rw_and_rw_remote_repo():
  + "Polish" most remote & config urls, converting \-->/.
  + test_base.test_with_rw_remote_and_rw_repo() PASS.
+ Remote: 
  + test_remote: apply polish-urls on `_do_test_fetch()` checking function.
  + test_remote.test_base() now freezes on Windows! (so still hidden win_err).
pump fetch-infos instead of GIL-reading stderr.
  + Push-cmd also keep (and optionally raise) any error messages.
+ `cmd.handle_process_output()` accepts null-finalizer, to pump completely
stderr before raising any errors.
+ test: Enable `TestGit.test_environment()` on Windows (to checks stderr
consumption).
+ util: delete unused `absolute_project_path()`.
+ Control separately *freezing* TCs on Windows with `git.util.HIDE_WINDOWS_FREEZE_ERRORS` flag.
ankostis added a commit to ankostis/smmap that referenced this issue Oct 22, 2016
Drop Windows only codepath bypassing memory-mapping due to some leaks in
the past. 
Now Appveyor proves everything run ok.  
Additionally, this codepath had unicode problems on PY3. So deleting it,
fixes 2 TCs in gitpython:
+ TestRepo.test_file_handle_leaks()
+ TestObjDbPerformance.test_random_access()

See gitpython-developers/GitPython#525
ankostis added a commit to ankostis/smmap that referenced this issue Oct 22, 2016
Drop Windows only codepath bypassing memory-mapping due to some leaks in
the past. 
Now Appveyor proves everything run ok.  
Additionally, this codepath had unicode problems on PY3. So deleting it,
fixes 2 TCs in gitpython:
+ TestRepo.test_file_handle_leaks()
+ TestObjDbPerformance.test_random_access()

See gitpython-developers/GitPython#525
ankostis added a commit to ankostis/smmap that referenced this issue Oct 22, 2016
Drop Windows only codepath bypassing memory-mapping due to some leaks in
the past. 
Now Appveyor proves everything run ok.  
Additionally, this codepath had unicode problems on PY3. So deleting it,
fixes 2 TCs in gitpython:
+ TestRepo.test_file_handle_leaks()
+ TestObjDbPerformance.test_random_access()

See gitpython-developers/GitPython#525
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants