from 5.9.0 to 5.12.0, behavior of open directory has changed?

when I use 5.9.0 and click file ->open, when I choose a file In the dialogue , the ‘OK’ button is actived to click; when I choose a directory In the diaglogue ,the ‘Ok’ buttuon is also activated. After I click ‘Ok’, the ‘open data with …’ dialogue will list all the directory reader filters.
Now when I use 5.12.0, when I choose a directory In the diaglogue ,the ‘Ok’ buttuon can not be activated. It is not convenient and is there any way to be back to 5.9.0 behavior.

I confirm that behavior was broken between 5.10 and 5.11.

@cory.quammen Is this an actual issue or is it voluntary ?

@utkarsh.ayachit @cory.quammen I believe this is by design. The issue we have is that some datasets are groups of files, others are folders. Navigate was chosen as the button that says “go into this folder”, OK says “Open this file or folder as a dataset”.

I think the problem is that the OK button is greyed out, so you cannot “Open this file or folder as a dataset”.

I remember having discussions about these features. As I recall, I thought the point was to navigate by default but allow you to open instead. The open feature seems to have gotten disabled.

I agree with @Kenneth_Moreland here. @mahb you may want to open an issue

Could anyone post an example dataset that shows this issue? If so, either write up the bug or if desired I can do it. Let me know where it is, I will add the Sandia tag to it.

So I looked into it more deeply, and I actually think it is not a bug.

There is currently N “directory” reader in ParaView:


However, all of these reader not only specify that they support reading directory, but directory with a specific naming scheme

Lets look at an example, ADIOS2VTXReader.

In the XML we can find:

        <ReaderFactory extensions="bp"
                       file_description="VTX reader: ADIOS2 BP3 File" />
        <ReaderFactory extensions="bp bp4"
                       file_description="VTX reader: ADIOS2 BP4 Directory" />

Which means the ParaView will allow you to open directory with this reader if and only if they are named something.bp or something.bp4

You can try for yourself, by creating an empty directory named test.bp4, ParaView will ungray the Ok button and you will be able to try opening it.

So my guess is that this feature has been augmented to allow not only named directory but directory with a specific name.

But wait, there is more! You can actually override that feature but selection “All files” instead of “Supported files” in the dialog.

Looping back to @mahb issue, please share the name of the folder you are trying to open and the expected reader you expect ParaView to find. You should be able to work around this feature by selecting “All files”.

Notes: Please don’t git blame, cause I may be the one implementing this two years ago :slight_smile:

Thanks a lot. I also find the work around way to open directory. but I will change the directory name or select ‘all files’. Compared with 5.9.0, It is not convient and the old users is hard to adjust.

What name does your original directory have and which reader are you trying to use ?

the reader is new that I customize many years ago.

    <ReaderFactory filename_patterns="*.br" file_description="File Format" is_directory="1" />

Before we upgrade to 5.12.0, when we choose directory ‘’, the OK button is ungray. and when we choose ‘dshang’,the OK button is also ungray.

This is a tough one. On one hand, enabling the OK button only when a directory follows a naming convention is consistent with the behavior of listing only single files in the file dialog that match a pattern supported by a reader. On the other hand, I can see the annoyance with having to select the All files as a “workaround” to open a directory that doesn’t follow a naming convention. However, that is consistent with having to use the same “workaround” to open a single file that doesn’t follow a known naming convention.

If we enable the OK button for any directory, then there is risk of of user accidentally opening a random directory and being confused about what just happened.

With that, I think the current behavior is overall more desirable than the previous behavior. If different naming conventions for datasets with a directory-based “file” arise within user communities, we can add patterns to support those conventions.

You just need to update your filename patterns to cover all usecases. Use “*” if needed.