Skip to content

BF(TST): RO operations - add test directory into git safe.directory #6726

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

Merged
merged 1 commit into from
Jun 2, 2022

Conversation

yarikoptic
Copy link
Member

Needed to overcome recent git safeguard. Test code comments provide
more information. Closes #6708 since I do not think we should do more
for this issue -- it would be up for a user indeed to add any given
directory owned by someone else into git config

I think it should be safe just to set it without store/restore handling
since our HOME is fake and set in the session wide fixture.

Needed to overcome recent git safeguard.  Test code comments provide
more information.  Closes datalad#6708 since I do not think we should do more
for this issue -- it would be up for a user indeed to add any given
directory owned by someone else into git config

I think it should be safe just to set it without store/restore handling
since our HOME is fake and set in the session wide fixture.
@yarikoptic
Copy link
Member Author

FWIW, I have just now cherry-picked @adswa 's d38fec7 fix for docs build into maint. So next build if ever to come should get green on that ;)

@yarikoptic yarikoptic added the semver-patch Increment the patch version when merged label May 31, 2022
@adswa
Copy link
Member

adswa commented Jun 1, 2022

One Windows run on Appveyor looked pretty bad (posting here for posterity/findability) and I restarted it

datalad.core.local.tests.test_create.test_create_withcfg ... run(ok): C:\DLTMP\datalad_temp_9xbdrrpd (dataset) ["C:\Python39-x64\python.exe" "c:\project...]
create(ok): . (dataset)
action summary:
  create (ok: 1)
  run (ok: 1)
Traceback (most recent call last):
  File "c:\projects\datalad\datalad\support\parallel.py", line 368, in _iter_threads
    raise _FinalShutdown()
datalad.support.parallel._FinalShutdown
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "c:\projects\datalad\datalad\resources\procedures\cfg_yoda.py", line 88, in <module>
    ds.save(
  File "c:\projects\datalad\datalad\distribution\dataset.py", line 502, in apply_func
    return f(*args, **kwargs)
  File "c:\projects\datalad\datalad\interface\utils.py", line 447, in eval_func
    return return_func(*args, **kwargs)
  File "c:\projects\datalad\datalad\interface\utils.py", line 439, in return_func
    results = list(results)
  File "c:\projects\datalad\datalad\interface\utils.py", line 357, in generator_func
    for r in _process_results(
  File "c:\projects\datalad\datalad\interface\utils.py", line 544, in _process_results
    for res in results:
  File "c:\projects\datalad\datalad\core\local\save.py", line 390, in __call__
    yield from ProducerConsumerProgressLog(
  File "c:\projects\datalad\datalad\support\parallel.py", line 535, in __iter__
    for res in super().__iter__():
  File "c:\projects\datalad\datalad\support\parallel.py", line 265, in __iter__
    yield from self._iter_threads(self._jobs)
  File "c:\projects\datalad\datalad\support\parallel.py", line 417, in _iter_threads
    self.shutdown(force=True, exception=self._producer_exception or interrupted_by_exception)
  File "c:\projects\datalad\datalad\support\parallel.py", line 233, in shutdown
    raise exception
  File "c:\projects\datalad\datalad\support\parallel.py", line 401, in _iter_threads
    done_useful |= self._pop_done_futures(lgr)
  File "c:\projects\datalad\datalad\support\parallel.py", line 463, in _pop_done_futures
    raise exception
  File "C:\Python39-x64\lib\concurrent\futures\thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "c:\projects\datalad\datalad\support\parallel.py", line 329, in consumer_worker
    for r in res:
  File "c:\projects\datalad\datalad\core\local\save.py", line 309, in save_ds
    for res in pds_repo.save_(
  File "c:\projects\datalad\datalad\support\gitrepo.py", line 3507, in save_
    self._save_post(message, chain(*status_state.values()), need_partial_commit, amend=amend,
  File "c:\projects\datalad\datalad\support\annexrepo.py", line 3535, in _save_post
    super(AnnexRepo, self)._save_post(
  File "c:\projects\datalad\datalad\support\gitrepo.py", line 3259, in _save_post
    GitRepo.commit(
  File "c:\projects\datalad\datalad\support\gitrepo.py", line 1421, in commit
    self._git_runner.run(
  File "c:\projects\datalad\datalad\runner\runner.py", line 201, in run
    raise CommandError(
datalad.runner.exception.CommandError: CommandError: '"git" "-c" "diff.ignoreSubmodules=none" "commit" "-m" "Apply YODA dataset setup" "--"' failed with exitcode 128 under C:\DLTMP\datalad_temp_9xbdrrpd\subds [err: 'error: external filter 'git-annex filter-process' failed
fatal: the remote end hung up unexpectedly']
run(error): C:\DLTMP\datalad_temp_9xbdrrpd\subds (dataset) ["C:\Python39-x64\python.exe" "c:\project...]
ERROR
datalad.core.local.tests.test_create.test_gh2927 ... ERROR
datalad.core.local.tests.test_create.test_nested_create ... ERROR
datalad.core.local.tests.test_diff.test_magic_number ... ERROR
datalad.core.local.tests.test_diff.test_diff ... ERROR
datalad.core.local.tests.test_diff.test_diff_fr_none_one_get_content_annexinfo_call ... ERROR
datalad.core.local.tests.test_diff.test_diff_nods ... ERROR
datalad.core.local.tests.test_diff.test_diff_nonexistent_ref_unicode ... ERROR
datalad.core.local.tests.test_diff.test_diff_recursive ... ERROR
datalad.core.local.tests.test_diff.test_diff_rsync_syntax ... ERROR
datalad.core.local.tests.test_diff.test_no_worktree_impact_false_deletions ... ERROR
datalad.core.local.tests.test_diff.test_path_diff ... ERROR
datalad.core.local.tests.test_diff.test_repo_diff ... ERROR
datalad.core.local.tests.test_resulthooks.test_basics ... ERROR
datalad.core.local.tests.test_results.test_generic_result_renderer ... ok
datalad.core.local.tests.test_run.test_py2_unicode_command ... SKIP: Skip test known to fail
datalad.core.local.tests.test_run.test_dry_run ... ERROR
datalad.core.local.tests.test_run.test_inject ... ERROR
datalad.core.local.tests.test_run.test_inputs_quotes_needed ... ERROR
datalad.core.local.tests.test_run.test_io_substitution ... ERROR
datalad.core.local.tests.test_run.test_run_from_subds_gh3551 ... ERROR
datalad.core.local.tests.test_run.test_run_save_deletion ... ERROR
datalad.core.local.tests.test_run.test_format_iospecs ... ok
datalad.core.local.tests.test_run.test_substitution_config ... ok
datalad.core.local.tests.test_run.test_basics ... ERROR
datalad.core.local.tests.test_run.test_format_command_strip_leading_dashes ... ERROR
datalad.core.local.tests.test_run.test_invalid_call ... ERROR
datalad.core.local.tests.test_run.test_run_assume_ready ... ERROR
datalad.core.local.tests.test_run.test_run_cmdline_disambiguation ... ERROR
datalad.core.local.tests.test_run.test_run_empty_repo ... ERROR
datalad.core.local.tests.test_run.test_run_explicit ... ERROR
datalad.core.local.tests.test_run.test_run_from_subds ... ERROR
datalad.core.local.tests.test_run.test_run_path_semantics ... ERROR
datalad.core.local.tests.test_run.test_run_reglob_outputs ... ERROR
datalad.core.local.tests.test_run.test_run_remove_keeps_leading_directory ... ERROR
datalad.core.local.tests.test_run.test_run_unexpanded_placeholders ... ERROR
datalad.core.local.tests.test_run.test_sidecar ... ERROR
datalad.core.local.tests.test_save.test_renamed_file(False, True) ... ERROR
datalad.core.local.tests.test_save.test_renamed_file(False, False) ... ERROR
datalad.core.local.tests.test_save.test_add_mimetypes ... SKIP: Skip test known to fail
datalad.core.local.tests.test_save.test_save_adjusted_partial ... SKIP: Skip test known to fail
datalad.core.local.tests.test_save.test_add_files ... ERROR
datalad.core.local.tests.test_save.test_add_subdataset ... ERROR
datalad.core.local.tests.test_save.test_bf2043p2 ... ERROR
datalad.core.local.tests.test_save.test_bf3285 ... ERROR
datalad.core.local.tests.test_save.test_encoding ... ERROR
datalad.core.local.tests.test_save.test_gh2043p1 ... ERROR
datalad.core.local.tests.test_save.test_on_failure_continue ... ERROR
datalad.core.local.tests.test_save.test_relpath_add ... ERROR
datalad.core.local.tests.test_save.test_save_amend ... ERROR
datalad.core.local.tests.test_save.test_save_obscure_name ... ERROR
datalad.core.local.tests.test_save.test_save_partial_commit_shrinking_annex ... ERROR
datalad.core.local.tests.test_save.test_surprise_subds ... ERROR
datalad.core.local.tests.test_save.test_add_recursive ... ERROR
datalad.core.local.tests.test_save.test_gh1597 ... ERROR
datalad.core.local.tests.test_save.test_gh1597_simpler ... ERROR
datalad.core.local.tests.test_save.test_partial_unlocked ... ERROR
datalad.core.local.tests.test_save.test_path_arg_call ... ERROR
datalad.core.local.tests.test_save.test_remove_subds ... ERROR
datalad.core.local.tests.test_save.test_save ... ERROR
datalad.core.local.tests.test_save.test_save_diff_ignore_submodules_config ... ERROR
datalad.core.local.tests.test_save.test_save_gitrepo_annex_subds_adjusted ... ERROR
datalad.core.local.tests.test_save.test_save_message_file ... ERROR
datalad.core.local.tests.test_save.test_save_nested_subs_explicit_paths ... ERROR
datalad.core.local.tests.test_save.test_subdataset_save ... ERROR
datalad.core.local.tests.test_save.test_subsuperdataset_save ... ERROR
datalad.core.local.tests.test_save.test_update_known_submodule ... ERROR
datalad.core.local.tests.test_save.test_save_dotfiles(True, None) ... ERROR
datalad.core.local.tests.test_save.test_save_dotfiles(True, 'nodot-subdir') ... ERROR
datalad.core.local.tests.test_save.test_save_dotfiles(False, None) ... ERROR
datalad.core.local.tests.test_save.test_save_dotfiles(False, 'nodot-subdir') ... ERROR
datalad.core.local.tests.test_save.test_save_dotfiles(None, None) ... ERROR
datalad.core.local.tests.test_save.test_save_dotfiles(None, 'nodot-subdir') ... ERROR
datalad.core.local.tests.test_save.test_bf1886 ... ERROR
datalad.core.local.tests.test_save.test_bf2541 ... ERROR
datalad.core.local.tests.test_save.test_symlinked_relpath ... ERROR
datalad.core.local.tests.test_save.test_windows_incompatible_names ... SKIP: Test incompatible with adjusted branch default
datalad.core.local.tests.test_status.test_get_paths_by_ds ... ERROR
datalad.core.local.tests.test_status.test_runnin_on_empty ... ERROR
datalad.core.local.tests.test_status.test_status ... ERROR
datalad.core.local.tests.test_status.test_status_basics ... ERROR
datalad.core.local.tests.test_status.test_status_nods ... ERROR
datalad.core.local.tests.test_status.test_status_symlinked_dir_within_repo ... ERROR
datalad.core.local.tests.test_status.test_subds_status ... ERROR
datalad.dataset.tests.test_gitrepo.test_fake_dates ... SKIP: Core GitRepo class does not have format_commit() yet
datalad.dataset.tests.test_gitrepo.test_gitrepo_call_git_methods ... ERROR
datalad.dataset.tests.test_gitrepo.test_init_fail_under_known_subdir ... ERROR
datalad.dataset.tests.test_gitrepo.test_GitRepo_equals ... ok
datalad.dataset.tests.test_gitrepo.test_GitRepo_flyweight ... ERROR
datalad.dataset.tests.test_gitrepo.test_GitRepo_init_options ... ERROR
datalad.dataset.tests.test_gitrepo.test_GitRepo_invalid_path ... ok
datalad.dataset.tests.test_gitrepo.test_get_dot_git ... ok
datalad.dataset.tests.test_gitrepo.test_GitRepo_instance_from_existing ... ERROR
datalad.dataset.tests.test_gitrepo.test_GitRepo_instance_from_not_existing ... ERROR
datalad.runner.tests.test_exception.test_format_error_with_duplicates ... ok
datalad.runner.tests.test_exception.test_format_no_errors ... ok
datalad.runner.tests.test_exception.test_command_error_rendering ... ok
datalad.runner.tests.test_generatormixin.test_generator_mixin_basic ... ok
datalad.runner.tests.test_generatormixin.test_generator_mixin_runner ... ok
datalad.runner.tests.test_generatormixin.test_post_pipe_callbacks ... ERROR
datalad.runner.tests.test_generatormixin.test_file_number_activity_detection ...       0 [main] echo 1229 C:\Program Files\Git\usr\bin\echo.exe: *** fatal error - unable to load user32.dll, Win32 error 8
    685 [main] echo 1229 cygwin_exception::open_stackdumpfile: Dumping stack trace to echo.exe.stackdump
ERROR
datalad.runner.tests.test_generatormixin.test_failing_process ... ok
datalad.runner.tests.test_gitrunner.test_gitrunner_generator ... ok
datalad.runner.tests.test_gitrunner.test_gitrunner_list ... ok
datalad.runner.tests.test_nonasyncrunner.test_subprocess_return_code_capture ... ok
datalad.runner.tests.test_nonasyncrunner.test_interactive_communication ... ok
datalad.runner.tests.test_nonasyncrunner.test_blocking_thread_exit ... deque([])
ok
datalad.runner.tests.test_nonasyncrunner.test_blocking_read_exception_catching ... ok
datalad.runner.tests.test_nonasyncrunner.test_blocking_read_closing ... ok
datalad.runner.tests.test_nonasyncrunner.test_popen_invocation ... SKIP: Skip test known to fail
datalad.runner.tests.test_nonasyncrunner.test_blocking_write_exception_catching ... ok
datalad.runner.tests.test_nonasyncrunner.test_blocking_writer_closing ... ok
datalad.runner.tests.test_nonasyncrunner.test_blocking_writer_closing_timeout_signal ... ok
datalad.runner.tests.test_nonasyncrunner.test_blocking_writer_closing_no_signal ... ok
datalad.runner.tests.test_nonasyncrunner.test_inside_async ... ok
datalad.runner.tests.test_nonasyncrunner.test_timeout ... FAIL
datalad.runner.tests.test_nonasyncrunner.test_timeout_nothing ... ok
datalad.runner.tests.test_nonasyncrunner.test_timeout_stdout_stderr ... ok
datalad.runner.tests.test_nonasyncrunner.test_timeout_process ... ok
datalad.runner.tests.test_nonasyncrunner.test_exit_3 ... ok
datalad.runner.tests.test_nonasyncrunner.test_exit_4 ...       0 [main] sleep 324 C:\Program Files\Git\usr\bin\sleep.exe: *** fatal error - unable to load user32.dll, Win32 error 8
    766 [main] sleep 324 cygwin_exception::open_stackdumpfile: Dumping stack trace to sleep.exe.stackdump
ERROR
datalad.runner.tests.test_nonasyncrunner.test_generator_throw ... ok
datalad.runner.tests.test_nonasyncrunner.test_exiting_process ...       0 [main] sleep 660 C:\Program Files\Git\usr\bin\sleep.exe: *** fatal error - unable to load user32.dll, Win32 error 8
   1197 [main] sleep 660 cygwin_exception::open_stackdumpfile: Dumping stack trace to sleep.exe.stackdump
exit
ok

@codecov
Copy link

codecov bot commented Jun 1, 2022

Codecov Report

Merging #6726 (e09e466) into maint (446d3c0) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##            maint    #6726   +/-   ##
=======================================
  Coverage   91.18%   91.19%           
=======================================
  Files         353      353           
  Lines       44528    44532    +4     
=======================================
+ Hits        40604    40609    +5     
+ Misses       3924     3923    -1     
Impacted Files Coverage Δ
datalad/support/tests/test_annexrepo.py 97.87% <100.00%> (+<0.01%) ⬆️
datalad/support/annexrepo.py 91.75% <0.00%> (+0.08%) ⬆️
datalad/_version.py 47.70% <0.00%> (+0.56%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 446d3c0...e09e466. Read the comment docs.

@yarikoptic
Copy link
Member Author

Thanks @adswa ! Since now it is as green as never before, I will label it for release, and if no objections/feedback -- will merge within a day. Specific blessing would facilitate that ;)

@yarikoptic yarikoptic added the release Create a release when this pr is merged label Jun 1, 2022
@yarikoptic yarikoptic merged commit 121f972 into datalad:maint Jun 2, 2022
@github-actions
Copy link

github-actions bot commented Jun 2, 2022

🚀 PR was released in 0.16.4 🚀

@yarikoptic yarikoptic deleted the bf-ro-operations branch July 11, 2022 19:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release Create a release when this pr is merged released semver-patch Increment the patch version when merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants