SmartQuant Discussion

Automated Quantitative Strategy Development, SmartQuant Product Discussion and Technical Support Forums
It is currently Thu Oct 01, 2020 10:58 am

All times are UTC + 3 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Thu Oct 18, 2012 5:18 pm 
Offline

Joined: Thu Jun 08, 2006 3:56 pm
Posts: 537
Location: BC Canada
Currently OQ stores Solution and Project files in different directories. This is a reasonable storage approach (two separate files) because it allows one project to be added to multiple solution files.

However, when I cleaned up my Projects directory by moving old project files into subfolders, and grouping many of my related project files into subfolders, OQ started crashing right after I rebooted it, when I tried to load a solution file that referenced one of the relocated projects.

I see two problems at work.

The first problem is that when OQ loads a solution file containing invalid pathnames to project files, OQ should validate (or gracefully respond to) missing project files. Currently my OQ (latest version) just crashes, but it would be better if it would pop up an error message to let me know what's going on, or give me a dialog so I can browse to the relocated project file (which OQ can then load as usual).

The second problem is that there is no GUI way for me to remove broken solution files from the Start Page. Eventually these broken solutions will roll off the recent solution list as I work on new solutions, but it would be nice to have an easier way (checkboxes, or right clicks) for me to manually remove broken solutions from the list.


Top
 Profile  
 
PostPosted: Fri Oct 19, 2012 7:44 am 
Offline

Joined: Tue Aug 05, 2003 3:43 pm
Posts: 6817
Hi Kevin,

thanks for pointing this out. We will try to fix it. On the other hand we are currently working on the framework integration into MS Visual Studio, so that we hope that Visual Studio itself will take care about all these issues regarding projects, solutions, directories, source control, etc.

Regards,
Anton


Top
 Profile  
 
PostPosted: Fri Oct 19, 2012 8:13 am 
Offline

Joined: Thu Jun 08, 2006 3:56 pm
Posts: 537
Location: BC Canada
Hopefully the VS extension will be useful for those who use VStudio, but for my two bits it looks like a really simple fix to check the project pathname before trying to load it. Probably you'll have to fix it anyway, since not everyone will be using VStudio (additional cost/complexity, etc, plus all the arguments that could be made in favor of VisualQuant because so many users were not professional programmers).

I think most people would be happy with a nice error message saying that

- the project file could not be found,
- that the project was removed from the solution so the solution would load, and
- that I could reload the project again by Add Project and browsing to the new location.


Top
 Profile  
 
PostPosted: Thu Oct 25, 2012 5:40 am 
Offline

Joined: Thu Jun 08, 2006 3:56 pm
Posts: 537
Location: BC Canada
It occurs to me that (I think) the Project pathname stored in the Solutions xml file should be a relative pathname such as ../Projects/MyOpenQuantProject.oqp, so that the Solution and Project files will continue to work if I relocate them in a similarly structured folder environment.

For example, the initial folder structure is:

OQ/Solutions/MySolution.oqs
OQ/Projects/MyProject.opq

where the MySolution.oqs file contains ../Projects/MyProject.opq.

If I relocate both the solution and project files to a new structure:

Obsolete/Solutions/MySolution.oqs
Obsolete/Projects/MyProject.opq

the solution file will still load, find the project file, and will be able to run simulations.


Top
 Profile  
 
PostPosted: Mon Oct 29, 2012 8:21 am 
Offline

Joined: Thu Jun 08, 2006 3:56 pm
Posts: 537
Location: BC Canada
Since the whole Start Page disappeared on me when OQ couldn't find one of the projects listed in the solution, I tried to restore all the projects in the solution so that the solution would load. The main problem here is that since the solution would not load, there was no way for me to find out which projects were in the solution. Bummer.

Eventually I renamed my solution.oqs file to give it an .xml suffix, so that I could load it into something to see what was inside. From there I could find out which projects I needed. So now I have my Start Page loading properly, and I can reload and run my solutions.

In the process of seeing what was inside the solution file, I saw that the pathnames to the projects were relative pathnames, which was what I was thinking in my previous post. Nice to see that my suggestion was not required.

I'm posting this to give the "rename to xml to see what's inside" technique, in case someone else encounters the problem and can use this method in the future.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC + 3 hours


Who is online

Users browsing this forum: Google [Bot] and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group