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

Report the name of an unreadable directory. #1522

Closed

Conversation

simonjwright
Copy link
Contributor

While working on a new external, I tried adding my local alire-index before the community index for testing. The error reported was "Not a readable directory". After 2 hours investigation (gdb ...) I realised that I’d been trying to add alr-index rather than alire-index.

This patch (which is in the style of other Outcome_Failure messages) would probably have saved that time!

  * src/alire/alire-index_on_disk.adb (New_Handler.Process_Local_Index):
      If the Path isn't a writable directory (e.g. because it doesn't
      exist), add it to the message in Outcome_Failure.
  * testsuite/tests/index/local-index-not-found/test.py: as summary.
  * testsuite/tests/index/local-index-not-found/test.py: as summary.
 * testsuite/tests/index/local-index-not-found/test.py: the input was
     "no-such-directory", but the output was "./no-such-directory".
     Fix the input to match that.
@simonjwright
Copy link
Contributor Author

Sorry, I’ve no idea how to fix this.

  * testsuite/tests/index/local-index-not-found/test.py (comparator): new.
    Use when preparing test condition.
@simonjwright
Copy link
Contributor Author

Sorry, this is just not worth it. Abandoned.

@simonjwright simonjwright deleted the report-unwritable-dir branch December 31, 2023 22:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant