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

Open database in local host #244

Closed
alamsyah78 opened this issue Jul 4, 2022 · 17 comments
Closed

Open database in local host #244

alamsyah78 opened this issue Jul 4, 2022 · 17 comments
Assignees
Labels
DNA GUI Issues related to the graphical user interface question version 3.0 Issues relating to version 3.0, including rDNA
Milestone

Comments

@alamsyah78
Copy link

I try to open the sample (sample.dna) using DNA 3.0. I follow these steps:

First, I create an SQLite database. No problem was found in this step (see Figure 1)
Second, I download the data sample (sample.dna) from Github and save it in the Documents folder. The problem is DNA 3 cannot detect files ( all files and *dna file) in the Documents folder (see Figure 2 and Figure 3)
Figure 1
Figure 2
Figure 3

@leifeld
Copy link
Owner

leifeld commented Jul 4, 2022

See the discussion and solutions in #201. Does this solve your problem?

@alamsyah78
Copy link
Author

No. I install Adopt OpenJDK version 11 with Hotspot JVM and give permission to the JAR file in the system setting. But, DNA 3.0 still does not detect my file.

Next, I create a new database (i.e., training.dna) and save it to my hard disk. I closed DNA 3. I open DNA 3.0 again and try to open training.dna file. Unfortunately, I do not find training.dna in my harddisk.

I use macOS Big Sur version 11.6.7.

Regards,

Screen Shot 2022-07-05 at 22 02 48

@leifeld
Copy link
Owner

leifeld commented Jul 5, 2022

Does it happen as well if you save the dna file in a Dropbox folder? This is not recommended, but may be useful for testing purposes. If you can then see the file, it means it's a MacOS file system issue. Perhaps you can report back.

@alamsyah78
Copy link
Author

Thank you very much for this discussion. I will try DNA 3.0 in Windows in the future. God bless you Prof. Leifeld.

@leifeld leifeld added question DNA GUI Issues related to the graphical user interface version 3.0 Issues relating to version 3.0, including rDNA labels Jul 5, 2022
@leifeld leifeld self-assigned this Jul 5, 2022
@leifeld
Copy link
Owner

leifeld commented Jul 5, 2022

Have you tried saving the dna file in another folder? Have you tried saving it in a Dropbox folder? It would be good to know these things to understand the nature of the problem better. Thanks.

@maikenmelanie
Copy link

Dear Prof. Leifeld, I have the same problem as described in this issue. I was successfully using the DNA 2.0 beta 25 version where I was always able to open the database in the local host. I recently updated my MacBook to the most recent Ventura 13.0 version and since then I am also not able to open the file anymore (undetectable as described in this issue). I tried both: opening it in the Mac file system and in a OneDrive folder, which was unsuccessful. I also checked (as described above) whether the JAR file has all the necessary permissions via the system settings (which it has).

@maikenmelanie
Copy link

Small update: Apparently the problem of not being able to see the content of some folders on my Mac does not extend to all folders, if I save the .dna file in the Pictures folder, I am able to open it in the local host.

@leifeld
Copy link
Owner

leifeld commented Nov 19, 2022

@maikenmelanie Thanks, this is a valuable hint about the Pictures folder. I found a similar problem with a different Java application, and it seems to be a problem with the MacOS security settings there.

You wrote that you were using DNA 2.0 beta 25. Can you try downloading the latest version 3.0.8 and try if the problem persists there? You can use the sample.dna database for this purpose or import your 2.0 data into a new database in order to try it out. I'm happy to try to diagnose the problem if it still persists in DNA 3, but I may need your help in trying it out as I don't have a Mac to try it out on with the same issue occurring.

@leifeld leifeld modified the milestones: DNA 3.0.9, DNA 3.0.10 Jan 8, 2023
leifeld added a commit that referenced this issue Feb 23, 2023
Up to (and including) DNA 3.0.9, DNA relied on the JFileChooser class to select files, for example in the dialog windows to open databases, create new databases, import documents from folders or other databases, open and save connection profiles, save log messages to XML or JSON, and export networks. While this works well on Windows and Linux, the security requirements of MacOS are too restrictive. Apple does not allow files to be displayed by the file chooser dialog (other than in Dropbox folders and the Pictures folder). In this update, I have consolidated all instances where a file chooser is used into a new FileChooser class and added a case selection to determine what operating system is being used. If it is MacOS, the native FileDialog is used instead of JFileChooser. This should allow Mac users to open and save files properly. The update fixes #244 and addresses parts of #201.
@leifeld
Copy link
Owner

leifeld commented Feb 23, 2023

I have fixed the MacOS problem, and the fix will be released in DNA 3.0.10 in March 2023. For now, there is a temporary version available. The changes in the code can be reviewed here. Let me know if this solves the issues.

@maikenmelanie
Copy link

maikenmelanie commented Feb 24, 2023 via email

@leifeld
Copy link
Owner

leifeld commented Feb 24, 2023

Thanks for getting back to me. Sorry to hear it's still not working. I have only one Mac to try it out with, and it worked there after making the changes. To diagnose the problem better, would you mind opening DNA, going to the message log (click on the little bug in the lower right corner, export the log as a JSON file, and post it here? That should include the operating system type, which is used to decide which file chooser to use. Thanks.

@maikenmelanie
Copy link

Yes, sure you can find the JSON file attached, hope it helps.
messagelog_dna_maiken.json.zip

@leifeld
Copy link
Owner

leifeld commented Feb 24, 2023

Thanks, much appreciated. I have an idea what may have gone wrong. Would you mind trying it with this new temporary version? Thanks.

@maikenmelanie
Copy link

Now I can navigate in my folders to the file location as I have been able to before, this is great. Yet, I get the following message when trying to open the DNA file:
Bildschirm­foto 2023-02-24 um 10 53 33
dnalog_maiken.json.zip

@leifeld
Copy link
Owner

leifeld commented Feb 24, 2023

Great! Yes, I noticed in the error log you sent that there was an uncaught error message about not being able to find some of the required tables in the database. My best guess was that you were trying to open a database created in DNA 2.0 with DNA 3.0. This is not possible because the data structures have changed. So I have now added a proper error message when that happens. If you click on the little bug symbol in the lower right corner of the DNA window, you will be able to see the full error message with version numbers and instructions. The good news is that there is an import function that is compatible with version 2 databases. You basically have to create a new database, set up any required coders, and then use the "Import from DNA database" dialog in the "Documents" menu to copy all the documents, statements etc into the new database. This works with database version 2 and 3.

@maikenmelanie
Copy link

maikenmelanie commented Feb 24, 2023 via email

@leifeld
Copy link
Owner

leifeld commented Feb 24, 2023

Happy to help. I'll close this as fixed.

@leifeld leifeld closed this as completed Feb 24, 2023
@leifeld leifeld modified the milestones: DNA 3.0.11, DNA 3.0.10 Mar 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DNA GUI Issues related to the graphical user interface question version 3.0 Issues relating to version 3.0, including rDNA
Projects
None yet
Development

No branches or pull requests

3 participants