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

[Bug]: Azure File Share ListDirectory not returning Attributes, Timestamps, ETag if requested #668

Closed
1 task done
MODUSCarstenScholling opened this issue Feb 29, 2024 · 1 comment · Fixed by #670
Closed
1 task done
Labels
Approved The issue is approved

Comments

@MODUSCarstenScholling
Copy link
Contributor

MODUSCarstenScholling commented Feb 29, 2024

Describe the issue

Azure File Share ListDirectory not returning Attributes, Timestamps, ETag if requested.

Expected behavior

Attributes, Timestamps and ETag must be populated in AFS Directory Content if requested.

Steps to reproduce

  var
        afsDirectoryContent: Record "AFS Directory Content";
        response: Codeunit "AFS Operation Response";
        parameters: Codeunit "AFS Optional Parameters";
  begin
        includeProperties.Add(Enum::"AFS Property"::Attributes);
        includeProperties.Add(Enum::"AFS Property"::Timestamps);
        includeProperties.Add(Enum::"AFS Property"::ETag);
        parameters.Include(includeProperties);

        parameters.FileExtendedInfo(true);

        response := AfsFileClient.ListDirectory(path, afsDirectoryContent, parameters);

        if response.IsSuccessful() then begin
            afsDirectoryContent.FindFirst();
            // TestField causes an error as this timestamp (among others) is never populated, never requested
            afsDirectoryContent.TestField("Creation Time");
        end;
    end;

Additional context

The reason for this:

Codeunit 8956 "AFS Optional Parameters"

WRONG:

    internal procedure GetParameters(): Dictionary of [Text, Text]
    begin
        AFSOptionalParametersImpl.GetParameters();
    end;

RIGHT:

    internal procedure GetParameters(): Dictionary of [Text, Text]
    begin
        exit(AFSOptionalParametersImpl.GetParameters());
    end;

I will provide a fix for a bug

  • I will provide a fix for a bug
@JesperSchulz
Copy link
Contributor

Yup! That's a no-brainer. Of course approved.

@JesperSchulz JesperSchulz added the Approved The issue is approved label Feb 29, 2024
JesperSchulz pushed a commit that referenced this issue Mar 1, 2024
<!-- Thank you for submitting a Pull Request. If you're new to
contributing to BCApps please read our pull request guideline below
* https://github.com/microsoft/BCApps/Contributing.md
-->
#### Summary
Actually return parameters to request to return attributes, timestamps,
etag if requested.

#### Work Item(s)
Fixes #668 


Fixes
[AB#503067](https://dynamicssmb2.visualstudio.com/1fcb79e7-ab07-432a-a3c6-6cf5a88ba4a5/_workitems/edit/503067)

---------

Co-authored-by: Gert Robyns <[email protected]>
JesperSchulz pushed a commit that referenced this issue Mar 5, 2024
<!-- Thank you for submitting a Pull Request. If you're new to
contributing to BCApps please read our pull request guideline below
* https://github.com/microsoft/BCApps/Contributing.md
-->
#### Summary
Actually return parameters to request to return attributes, timestamps,
etag if requested.

#### Work Item(s)
Fixes #668 


Fixes
[AB#503067](https://dynamicssmb2.visualstudio.com/1fcb79e7-ab07-432a-a3c6-6cf5a88ba4a5/_workitems/edit/503067)

---------

Co-authored-by: Gert Robyns <[email protected]>
JesperSchulz pushed a commit that referenced this issue Mar 5, 2024
<!-- Thank you for submitting a Pull Request. If you're new to
contributing to BCApps please read our pull request guideline below
* https://github.com/microsoft/BCApps/Contributing.md
-->
#### Summary
Actually return parameters to request to return attributes, timestamps,
etag if requested.

#### Work Item(s)
Fixes #668 


Fixes
[AB#503067](https://dynamicssmb2.visualstudio.com/1fcb79e7-ab07-432a-a3c6-6cf5a88ba4a5/_workitems/edit/503067)

---------

Co-authored-by: Gert Robyns <[email protected]>
JesperSchulz added a commit that referenced this issue Mar 6, 2024
<!-- Thank you for submitting a Pull Request. If you're new to
contributing to BCApps please read our pull request guideline below
* https://github.com/microsoft/BCApps/Contributing.md
-->
#### Summary <!-- Provide a general summary of your changes -->
Backport of #670 

#### Work Item(s) <!-- Add the issue number here after the #. The issue
needs to be open and approved. Submitting PRs with no linked issues or
unapproved issues is highly discouraged. -->
Fixes
[AB#504264](https://dynamicssmb2.visualstudio.com/1fcb79e7-ab07-432a-a3c6-6cf5a88ba4a5/_workitems/edit/504264)

Co-authored-by: Carsten Scholling (MODUS Consult) <[email protected]>
Co-authored-by: Gert Robyns <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Approved The issue is approved
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants