Community Event / Creation TradeDangerous GUI front end

I haven't been using it much, so let me know what I can do to improve it.

Great work!

-Ol

Thanks! :)

This might get a little long for a suggestion, but here I go...

I've been slowly working on a rewrite that would try to eventually accomplish the following:

* Establish a loop (if possible) of clusters of rare stations based on criteria like maximum loop distance (200ly say, beyond the optimal profit range), maximum willing jump distance between clusters (like 90-120ly, something near optimal profit distance) or a minimum sell distance (such as 140ly or so), and a maximum number of stations to visit.

* Calculate along the path to account for reachability and try to determine which stations to stop at to sell specific items we've picked up when the optimal/chosen distance for profit is reached.

* Ultimately try to end up either near our arbitrary starting point or near another cluster.

From what I can tell from a fair bit of poking around no other rare route calculator can do all that with one tool efficiently without taking ages like TradeDangerous can. So far, I've been able to create several groups of rare clusters based on criteria/profit. I'm still working out how to connect clusters in an efficient way using TradeCalc, but Python isn't my main language so it's taking me longer than I expected it would.
 
Just pushed v1.04a with lots of goodies like Station/ShipVendor/Nav support. See the changelog for details.

(Edit: I'm aware of a minor and rare delegate worker bug that kills the Run button once in a blue moon. Switching commands a few times might fix it. I'll squash it permanently in the next major release.)
 
Last edited:
Can you help me with the path to the ED logs please. I cannot use the app because I don't know where they are

Is it strictly necessary to know where the log is? I know for example that EliteOCR can do extra stuff if you tell it where the log is, but it still works without knowing.
 
Can you help me with the path to the ED logs please. I cannot use the app because I don't know where they are

Is it strictly necessary to know where the log is? I know for example that EliteOCR can do extra stuff if you tell it where the log is, but it still works without knowing.

In order for the program to get the previous systems you've visited it has to read the net log. When the program asks for the net logs it should start you off very close to where they are; somewhere under:

c:\Users\USERNAME\AppData\Local\Frontier_Developments\Products\LAUNCHERDIRECTORY\Logs

The "USERNAME" and "LAUNCHERDIRECTORY" can be different, for instance my launcher directory is: FORC-FDEV-D-1003. Hope that helps.

(Edit: It should also be noted that if you haven't had VerboseLogging turned on before logging in, the frontend will fix it for you and ask you to relog so the game can read the net log.)
 
Last edited:
Thank you. Mine was actually in the path of the game installation. P:\Program Files (x86)\Frontier\EDLaunch\Products\FORC-FDEV-D-1002\Logs

So I cannot get it to produce any output now. If I type in a trade.py run line at the command prompt, and ensure that it produces results, and then 'synthesise' it in your GUI, no output is being produced. In your output tab

Code:
Command line: -u "P:\Program Files (x86)\td\trade.py" run --fr="eta/fisk" --to="eta/fisk" --cap=208 --ins=713000 --cr=1383830 --ly=11.04 --pad=L --hops=4 --jum=2 -vvv

If I copy and paste that into a dos window (without the -u prefix) it works fine.
 
Thank you. Mine was actually in the path of the game installation. P:\Program Files (x86)\Frontier\EDLaunch\Products\FORC-FDEV-D-1002\Logs

So I cannot get it to produce any output now. If I type in a trade.py run line at the command prompt, and ensure that it produces results, and then 'synthesise' it in your GUI, no output is being produced. In your output tab

Code:
Command line: -u "P:\Program Files (x86)\td\trade.py" run --fr="eta/fisk" --to="eta/fisk" --cap=208 --ins=713000 --cr=1383830 --ly=11.04 --pad=L --hops=4 --jum=2 -vvv

If I copy and paste that into a dos window (without the -u prefix) it works fine.

Hmm.. it sounds like your python environment might be a bit odd. I would double check the version of python you're running. Any of the 3.4 versions should work fine from the official python website: https://www.python.org/downloads/. I'm currently using 3.4.2.
 
Because I had problems with the first run (not knowing where my log file was) I deleted the program and restarted from scratch. Now I have a different problem.

Previously, the Output tab displayed as I showed above, and the Elapsed time remained at zero. Now I get the same Output, but the Elpased timer is updating.

Very peculiar, not had problems with trade.py at the command line at all, but will check Python version.

Might the problem be because I have VS Express 2013 for Desktop installed? I know that causes issues for EliteOCR.

Edit: Closing the app and starting it again goes back to the initial behaviour of the Elapsed timer not changing.
Edit: Python version is 3.4.1 for Windows 64-bit
 
Last edited:
Because I had problems with the first run (not knowing where my log file was) I deleted the program and restarted from scratch. Now I have a different problem.

Previously, the Output tab displayed as I showed above, and the Elapsed time remained at zero. Now I get the same Output, but the Elpased timer is updating.

Very peculiar, not had problems with trade.py at the command line at all, but will check Python version.

Might the problem be because I have VS Express 2013 for Desktop installed? I know that causes issues for EliteOCR.

As far as I know it shouldn't cause any problems. Although, I know from my own testing that if the python environment is weird about which executables are considered default (like pythonw.exe being the main executable instead of python.exe) TDHelper can act very strange. I would check to see what the output of "python.exe --version" is in a console window for posterity.

In an upcoming update I'll see what I can do about being smarter about which executables the frontend tries to use.
 
Code:
P:\>set pathPath=C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;P:\Program Files\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\Program Files (x86)\AMD\ATI.ACE\Core-Static
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY


P:\>cd Python34


P:\Python34>python.exe --version
Python 3.4.1


P:\Python34>python
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:45:13) [MSC v.1600 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> exit()


P:\Python34>

So Python isn't on my PATH. Does your code depend on this? I'd imagine not as the Output tab shows the whole path.

SIDE NOTE: I don't really understand how any of the .py scripts are executed without Python on the path. I assume that the PATHEEXT setting means that Windows goes a looks for an association in the registry?
 
Code:
P:\>set pathPath=C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;P:\Program Files\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\Program Files (x86)\AMD\ATI.ACE\Core-Static
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY


P:\>cd Python34


P:\Python34>python.exe --version
Python 3.4.1


P:\Python34>python
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:45:13) [MSC v.1600 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> exit()


P:\Python34>

So Python isn't on my PATH. Does your code depend on this? I'd imagine not as the Output tab shows the whole path.

SIDE NOTE: I don't really understand how any of the .py scripts are executed without Python on the path. I assume that the PATHEEXT setting means that Windows goes a looks for an association in the registry?

Unfortunately, you're going to have to add the path to the windows path variable, or reinstall python so the installer can set it under the environment variables. In the next update I'll include a way to manually select the python executable in the event that it can't be found in the path. I had assumed everyone had a working python install with the path in the path variable, but I guess I was over optimistic in accounting for user environments.
 
would like to suggest functionality for the -checklist option in TD. Also would like to suggest the ability to be able to export --table station with the TDHelper for those pesky stations that get local placeholders.

Also I would like to note (possibly this is the intent) that my source and destination boxes only have systems that I have visited while using this program available for search, I'm not sure if that's the intent, or if in similarity with say QAA that the user would be able to select any known system that may or may not have trade data, but are known systems. It would be nice to be able to select systems and then even possibly stations much like you can in QAA.
 
would like to suggest functionality for the -checklist option in TD. Also would like to suggest the ability to be able to export --table station with the TDHelper for those pesky stations that get local placeholders.

Also I would like to note (possibly this is the intent) that my source and destination boxes only have systems that I have visited while using this program available for search, I'm not sure if that's the intent, or if in similarity with say QAA that the user would be able to select any known system that may or may not have trade data, but are known systems. It would be nice to be able to select systems and then even possibly stations much like you can in QAA.

Good timing! I was about to finish up v1.04b, but I'll see what I can do about adding something as simple as table exporting.

As for the system/station persistence; I'm still exploring the best method to do that. QAA/Slopey's both use a database parse for known systems which is time intensive and expensive (hence the long load times and overall UI sluggishness). I would like very much to avoid anything so bloated, so I've been considering adding in a user-centric persistence that would persist whatever systems/stations the user enters within reason (50 entries or so). I'm actually finishing up a temporary version of it for this upcoming update.

I feel your pain though, and I miss having full persistence too. I tend to use TD's local command quite a bit to kind of work around that, but it's obviously far from perfect. I'll keep working on trying to find an efficient and fast way of having full system/station persistence from the TD database. Don't expect it soon, as I'm in the process of refactoring a bunch of code for the move to GridView support (which would allow sorting longer routes and a cleaner output).

As for checklist support, it's unlikely to happen as it would require the user to enter inputs into the output box for each step of the checklist. Sorry. :(

I appreciate the suggestions though.
 
Last edited:
Good timing! I was about to finish up v1.04b, but I'll see what I can do about adding something as simple as table exporting.

As for the system/station persistence; I'm still exploring the best method to do that. QAA/Slopey's both use a database parse for known systems which is time intensive and expensive (hence the long load times and overall UI sluggishness). I would like very much to avoid anything so bloated, so I've been considering adding in a user-centric persistence that would persist whatever systems/stations the user enters within reason (50 entries or so). I'm actually finishing up a temporary version of it for this upcoming update.

I feel your pain though, and I miss having full persistence too. I tend to use TD's local command quite a bit to kind of work around that, but it's obviously far from perfect. I'll keep working on trying to find an efficient and fast way of having full system/station persistence from the TD database. Don't expect it soon, as I'm in the process of refactoring a bunch of code for the move to GridView support (which would allow sorting longer routes and a cleaner output).

As for checklist support, it's unlikely to happen as it would require the user to enter inputs into the output box for each step of the checklist. Sorry. :(

I appreciate the suggestions though.

Awesome, table exporting would be a nice little touch. On the note of system/station persistence, I totally understand where you're coming from, and I will gladly wait patiently for System/Station persistence as currently TD and QAA are my favorite tools, but QAA took the cake due to the GUI that TD so desperately lacked, of course in my opinion, but when I found this niffty frontend, TD/TDHelper slowly started stealing pieces of that cake from QAA and gobbling them down with a devilish look in their eyes, I fully fully look forward to the future of TDHelper and the future of QAA, they both have amazing potential and they both satisfy different needs in their own respect. Love love love the support on this tool as well, very involved + all the cookies for you Sir.

On the note of checklist support, I understand that, and I can see why that wouldn't be very efficient, would be a neat feature, but it's definitely not something that's going to stop me from enjoying the frontend you've created for TD
 
Awesome, table exporting would be a nice little touch. On the note of system/station persistence, I totally understand where you're coming from, and I will gladly wait patiently for System/Station persistence as currently TD and QAA are my favorite tools, but QAA took the cake due to the GUI that TD so desperately lacked, of course in my opinion, but when I found this niffty frontend, TD/TDHelper slowly started stealing pieces of that cake from QAA and gobbling them down with a devilish look in their eyes, I fully fully look forward to the future of TDHelper and the future of QAA, they both have amazing potential and they both satisfy different needs in their own respect. Love love love the support on this tool as well, very involved + all the cookies for you Sir.

On the note of checklist support, I understand that, and I can see why that wouldn't be very efficient, would be a neat feature, but it's definitely not something that's going to stop me from enjoying the frontend you've created for TD

Well, I have some good news and some slightly bad news on that front. The bad news first: v1.04b is taking me a little bit longer than I thought due to feature creep. The good news: I'm almost done implementing true System/Station persistence by reading directly out of the TD database. Yeah, I know I just said I didn't want to for various reasons, but I thought about it for awhile and realized that I'm going to implement it sooner or later anyway. Why not now?

It's probably going to take me a few more days to polish everything and bug test it properly. I'm not making guarantees on how responsive grabbing stuff out of the database will be right out of the gate (although it's looking pretty promising at the moment). I may even include an override so the user can just turn it off if they don't like any sluggishness (leaving just the user-centric persistence behind instead).
 
Finally finished with v1.04b, and I even got it done a little earlier than I thought I would.

Just in time for the Elite: Dangerous 1.2 wings update. :)
 
Unfortunately, you're going to have to add the path to the windows path variable, or reinstall python so the installer can set it under the environment variables. In the next update I'll include a way to manually select the python executable in the event that it can't be found in the path. I had assumed everyone had a working python install with the path in the path variable, but I guess I was over optimistic in accounting for user environments.

So I installed Python originally using the installer. I don't know why the path wasn't added to the PATH environment variable.

(Nor do I understand why typing in trade.py ran without the PATH variable set correctly, but that's a different thing for me to worry about)

Anyway, FYI manually editing the PATH variable to add Python has got rid of the problem, and your program now works, thanks! :)
 
So I installed Python originally using the installer. I don't know why the path wasn't added to the PATH environment variable.

(Nor do I understand why typing in trade.py ran without the PATH variable set correctly, but that's a different thing for me to worry about)

Anyway, FYI manually editing the PATH variable to add Python has got rid of the problem, and your program now works, thanks! :)

I've added a bunch of supporting code in v1.04b to help prevent having to manually add the Python path if the user doesn't have it already. It seems that sometimes for older Python installers in the 3.x series they didn't always add the path for the current user.

Also, I'm going to pose an open question to anyone reading this: I'm trying to refactor the code that pulls Systems/Stations from the database, and I'm thinking of making a trade-off in removing Systems without Stations from the autocomplete list. I think I can make the query/processing faster by skipping those systems (except our most recent systems visited), since when the user updates the DB by adding entries we can simply add those new stations on the next refresh of the local DB. It would save parsing like 11,000 entries that have no Stations and a moderate amount of processing time.

Is there any reason to have lots of Systems (for autocomplete) that have no stations that anyone can think of?
 
Okay, so I just pushed v1.04c after I found a bunch of silly performance hogging bugs that just had to be fixed.

I managed to get the parsing of the database down into the 20ms - 150ms range without any major tradeoffs in usefulness. Hooray!

(Edit: Net log issues in the original v1.04c should be fixed now. Cheers.)
 
Last edited:
Just downloaded 1.04c and I'm getting this error on startup:

See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.


************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at TradeDangerousGUI.AppSettings.loadWinLoc(Form x)
at TradeDangerousGUI.Form1.Form1_Load(Object sender, EventArgs e)
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)




************** Loaded Assemblies **************
mscorlib
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.34014 built by: FX45W81RTMGDR
CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
TradeDangerousGUI
Assembly Version: 1.0.0.3
Win32 Version: 1.0.0.3
CodeBase: file:///C:/Users/Jordan/Desktop/TradeDangerousGUI.exe
----------------------------------------
System.Windows.Forms
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.33440 built by: FX45W81RTMREL
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.33440 built by: FX45W81RTMREL
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.34239 built by: FX452RTMGDR
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Configuration
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.33440 built by: FX45W81RTMREL
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Core
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.33440 built by: FX45W81RTMREL
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
System.Xml
Assembly Version: 4.0.0.0
Win32 Version: 4.0.30319.34230 built by: FX452RTMGDR
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------


************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.


For example:


<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>


When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.


EDIT: Hmm, funky, I launched it directly from the folder rather than the shortcut I have, and the issue went away.

EDIT 2: Yep, it was the shortcut, I think it was because the shortcut was for a way older version of TDHelper and it was just causing issues, but I've created a new shortcut and everything seems to be fine.
 
Last edited:
Back
Top Bottom