timeseries / qstudio

qStudio - Free SQL Analysis Tool
https://www.timestored.com/qstudio/
Apache License 2.0
416 stars 17 forks source link

qStudio 3.03 on Mac - I can no longer open my SQLite file #47

Closed richb-hanover closed 3 weeks ago

richb-hanover commented 1 month ago

My original experiments with qStudio 3.02 on Mac went great (until I tried to execute a PRQL query.). I opened my local SQLite database, and issued SQL queries that worked as expected.

Using 3.03, I was able to enter small PRQL queries and it a) called the prqlc compiler to generate the expected SQL, and b) displayed the expected results. I had trouble entering a large query (generates 100-150 line of SQL) - I got some error code.

So I decided to set up a reproducible test case with these steps:

In a terminal:

In the GUI:

I see two results:

  1. The database does NOT seem to be connected:

    • I do not see its list of table names
    • Entering a simple command select * from ScrapedData gives: org.sqlite.SQLiteException: [SQLITE_ERROR] SQL error or missing database (no such table: ScrapedData)
  2. Sometimes I see a message to the effect that "the database is ~7 mbytes, and may take time to load" The GUI then hangs up (spinning beach ball of death). Several (5-7?) minutes later the GUI becomes responsive again, and I can attempt a command, but then I see the error above.

How can I troubleshoot this? Thanks.

ryanhamilton commented 4 weeks ago

Thanks for this detailed error report.

I do not see its list of table names Can you check if an empty file with a similar name was created? If you supply an incorrect path, it will automatically create an empty file.

Sometimes I see a message to the effect that "the database is ~7 mbytes, and may take time to load" qStudio is trying to load the file as text for editing. I will fix this.

richb-hanover commented 4 weeks ago

Update: I don't know what I did to get into this state, but here's where things stand:

What other info can I provide? Many thanks.

√ ~ % cd /Applications/qStudio
√ qStudio % java -jar qstudio.jar
Jun 02, 2024 7:40:18 PM com.timestored.misc.DynamicClassLoader loadInstances
INFO: Searching for plugins in folder: /Users/richb/qstudio/libs
Jun 02, 2024 7:40:18 PM com.timestored.misc.DynamicClassLoader visitJarFileJavaClasses
INFO: Looking for plugins inside: /Users/richb/qstudio/libs/sqlite-jdbc-3.42.0.0.jar
Jun 02, 2024 7:40:18 PM com.timestored.misc.DynamicClassLoader loadInstances
INFO: Searching for plugins in folder: /Users/richb/qstudio/libs
Jun 02, 2024 7:40:18 PM com.timestored.misc.DynamicClassLoader visitJarFileJavaClasses
INFO: Looking for plugins inside: /Users/richb/qstudio/libs/sqlite-jdbc-3.42.0.0.jar
Jun 02, 2024 7:40:18 PM com.timestored.misc.DynamicClassLoader$InstanceFinderVisitor visit
INFO: Found Plugin with correct interface: org.sqlite.JDBC
Jun 02, 2024 7:40:18 PM com.timestored.qstudio.QStudioLauncher main
SEVERE: Could not load a plugin due to Unable to make protected void java.net.URLClassLoader.addURL(java.net.URL) accessible: module java.base does not "opens java.net" to unnamed module @40f9161a
/Applications/qStudio
Jun 02, 2024 7:40:18 PM com.timestored.docs.OpenDocumentsModel addDocument
INFO: addDocument: new 1
Warning: the fonts "Times" and "Times" are not available for the Java logical font "Serif", which may have unexpected appearance or behavior. Re-enable the "Times" font to remove this warning.
Jun 02, 2024 7:40:20 PM com.timestored.qstudio.QStudioLauncher$2 launch
INFO: Starting QStudioLauncher  launch() ###################################
Jun 02, 2024 7:40:20 PM com.timestored.qstudio.QStudioLauncher$2 launch
INFO: System.getProperty("java.version")=16.0.1
Jun 02, 2024 7:40:20 PM com.timestored.connections.ConnectionManager reloadFromPreferences
WARNING: stored conns and current conns disagreed, using stored values
Jun 02, 2024 7:40:20 PM com.timestored.connections.ConnectionManager reloadFromPreferences
WARNING: serverConns = []
Jun 02, 2024 7:40:20 PM com.timestored.connections.ConnectionManager reloadFromPreferences
WARNING: sConns = [ServerConfig{name=sqlite:{file}, username=, host=localhost, port=0, cstoreType=SQLITE_JDBC, database=jdbc:sqlite:{file}}]
SLF4J(W): No SLF4J providers were found.
SLF4J(W): Defaulting to no-operation (NOP) logger implementation
SLF4J(W): See https://www.slf4j.org/codes.html#noProviders for further details.
Jun 02, 2024 7:40:20 PM com.timestored.qstudio.QStudioFrame <init>
INFO: Starting QStudioFrame Constructor
MODELS = 129.331151
Warning: the fonts "Times" and "Times" are not available for the Java logical font "Serif", which may have unexpected appearance or behavior. Re-enable the "Times" font to remove this warning.
Warning: the fonts "Times" and "Times" are not available for the Java logical font "Serif", which may have unexpected appearance or behavior. Re-enable the "Times" font to remove this warning.
Jun 02, 2024 7:40:21 PM com.timestored.swingxx.FileTreePanel refreshGui
INFO: FileTreePanel refreshGui
Jun 02, 2024 7:40:21 PM com.timestored.swingxx.FileTreePanel refreshGui
INFO: FileTreePanel refreshGui
Jun 02, 2024 7:40:21 PM com.timestored.qstudio.servertree.ServerListPanel refreshGui
INFO: refreshGui
Jun 02, 2024 7:40:21 PM com.timestored.sqldash.model.AbstractWidget configChanged
INFO: Widget 0 configChanged
Jun 02, 2024 7:40:21 PM com.timestored.sqldash.model.AbstractWidget configChanged
INFO: Widget 0 configChanged
Jun 02, 2024 7:40:21 PM com.timestored.swingxx.FileTreePanel refreshGui
INFO: FileTreePanel refreshGui
ENDER = 1122.300628
Jun 02, 2024 7:40:21 PM com.timestored.qstudio.model.AdminModel refresh
INFO: AdminModel hard Refresh
Jun 02, 2024 7:40:21 PM com.timestored.qstudio.QStudioFrame <init>
INFO: Finished QStudioFrame Constructor
Jun 02, 2024 7:40:21 PM com.timestored.qstudio.servertree.ServerListPanel refreshGui
INFO: refreshGui
Jun 02, 2024 7:40:21 PM com.timestored.docs.OpenDocumentsModel setSelectedFolder
INFO: setSelectedFolder: /Applications/qStudio
Jun 02, 2024 7:40:21 PM com.timestored.swingxx.FileTreePanel setRoot
INFO: root changing
Jun 02, 2024 7:40:21 PM com.timestored.qdoc.OpenDocumentsDocSource findFiles
INFO: Searched 1 directories and found 0 matches for .q
Jun 02, 2024 7:40:22 PM com.timestored.qstudio.QStudioLauncher$2 launch
INFO: Ending QStudioLauncher launch()
Jun 02, 2024 7:40:22 PM com.timestored.swingxx.FileTreePanel refreshGui
INFO: FileTreePanel refreshGui
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel addDocument
INFO: addDocument: new 2
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel addDocument
INFO: addDocument: new 3
Jun 02, 2024 7:40:22 PM com.timestored.plugins.PluginLoader getCClass
INFO: Could not find class already loaded. Refreshing from folders / jars.
Jun 02, 2024 7:40:22 PM com.timestored.docs.BackgroundDocumentsSaver restoreDocuments
INFO: attempting to restore existing known document
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel openDocument
INFO: openDocument: Property_In_Lyme.sqlite
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: Property_In_Lyme.sqlite
Jun 02, 2024 7:40:22 PM com.timestored.docs.BackgroundDocumentsSaver restoreDocuments
INFO: attempting to restore existing known document
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel openDocument
INFO: openDocument: Non-conf_Buildings.prql
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: Non-conf_Buildings.prql
Jun 02, 2024 7:40:22 PM com.timestored.docs.BackgroundDocumentsSaver restoreDocuments
INFO: attempting to restore existing known document
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel openDocument
INFO: openDocument: junk.prql
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: junk.prql
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel addDocument
INFO: addDocument: new 4
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel closeDocument
INFO: closeDocument: new 1
Jun 02, 2024 7:40:22 PM com.timestored.connections.ConnectionManager statusUpdate
INFO: sqlite:{file} Connected = true
Jun 02, 2024 7:40:22 PM com.timestored.qstudio.servertree.ServerListPanel refreshGui
INFO: refreshGui
Jun 02, 2024 7:40:22 PM com.timestored.qstudio.model.AdminModel$2 run
INFO: refreshing sqlite:{file}
Jun 02, 2024 7:40:22 PM com.timestored.qstudio.servertree.ServerListPanel refreshGui
INFO: refreshGui
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: new 6
Jun 02, 2024 7:40:22 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: new 1
Jun 02, 2024 7:40:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:41:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:41:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:42:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:42:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:43:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:43:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:44:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:44:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:45:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:45:39 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: Property_In_Lyme.sqlite
Jun 02, 2024 7:45:39 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: Non-conf_Buildings.prql
Jun 02, 2024 7:45:39 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: junk.prql
Jun 02, 2024 7:45:39 PM com.timestored.docs.OpenDocumentsModel setSelectedDocument
INFO: setSelectedDocument: new 5
Jun 02, 2024 7:45:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:46:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:46:51 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
Jun 02, 2024 7:47:21 PM com.timestored.docs.BackgroundDocumentsSaver requestSave
INFO: skipping persistOpenDocuments
richb-hanover commented 3 weeks ago

Let's close this in favor of other reports. Thanks!