Skip to content

Commit

Permalink
Merge branch 'master' into devel
Browse files Browse the repository at this point in the history
  • Loading branch information
bgol committed Apr 6, 2015
2 parents 813223f + 2d7809f commit e6b00f1
Show file tree
Hide file tree
Showing 9 changed files with 556 additions and 265 deletions.
4 changes: 4 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
TradeDangerous, Copyright (C) Oliver "kfsone" Smith, July 2014
==============================================================================

v6.17.3 Apr 05 2015
. (kfsone) Fixed a problem when distance pruning removed everything
. (kfsone) Added "--summary" to "run" for a cleaner summary route (use with -vvv)

v6.17.2 Apr 04 2015
. (kfsone) "buy" command
- Show ship costs when listing multiple ships,
Expand Down
4 changes: 4 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,10 @@ RUN sub-command:
Only show routes which do not visit any station twice

Other options:
--summary
Uses a slightly different format for showing trade routes,
especially useful for longer routes in conjunction with -vvv

--routes N DEFAULT: 1
Shows the top N routes;

Expand Down
3 changes: 0 additions & 3 deletions commands/olddata_cmd.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,6 @@ def run(results, cmdenv, tdb):
row.dist = dist2 ** 0.5
results.rows.append(row)

if cmdenv.near:
results.rows.sort(key=lambda row: row.dist)

if cmdenv.route and len(results.rows) > 1:
def walk(startNode, dist):
rows = results.rows
Expand Down
9 changes: 9 additions & 0 deletions commands/run_cmd.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,10 @@
default=None,
type=int,
),
ParseArgument('--summary',
help='Summary layout of route instructions.',
action='store_true',
),
]

######################################################################
Expand Down Expand Up @@ -1071,6 +1075,11 @@ def routeStillHasAChance(r):

preCrop = len(routes)
routes[:] = [x for x in routes if routeStillHasAChance(x)]
if not routes:
raise NoDataError(
"No routes are in-range of any end stations at the end of hop {}"
.format(hopNo)
)
pruned = preCrop - len(routes)
if pruned:
cmdenv.NOTE("Pruned {} origins too far from any end stations", pruned)
Expand Down
1 change: 0 additions & 1 deletion data/RareItem.csv
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
'AROUCA','Shipton Orbital','Arouca Conventula Sweets',1203,0
'AZ CANCRI','Fisher Station','Az Cancri Formula 42',6442,7
'BALTAH''SINE','Baltha''Sine Station','Baltha''sine Vacuum Krill',825,18
'BANKI','Parsons Vista','Banki Amphibious Leather',634,18
'BAST','Hart Station','Bast Snake Gin',1080,10
'BELALANS','Boscovich Ring','Belalans Ray Leather',882,11
'BORASETANI','Katzenstein Terminal','Borasetani Pathogenetics',8269,0
Expand Down
109 changes: 109 additions & 0 deletions data/ShipVendor.csv
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,18 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'AROUCA','Shipton Orbital','Type 6','2015-03-27 08:46:37'
'ARQUE','Austen Town Station','Cobra','2015-03-27 18:13:20'
'ARQUE','Austen Town Station','Type 9','2015-03-27 18:13:20'
'ATATA','Zahn Enterprise','Adder','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Anaconda','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Asp','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Cobra','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Dropship','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Eagle','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Hauler','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Orca','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Sidewinder','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Type 9','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Viper','2015-04-06 07:25:49'
'ATATA','Zahn Enterprise','Vulture','2015-04-06 07:25:49'
'ATTACATES','Buckell Ring','Cobra','2015-03-04 19:50:35'
'ATTACATES','Buckell Ring','Eagle','2015-03-04 19:50:35'
'ATTACATES','Buckell Ring','Sidewinder','2015-03-04 19:50:35'
Expand Down Expand Up @@ -452,6 +464,9 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'DIMOCO','Meitner Ring','Eagle','2015-03-04 19:50:35'
'DIMOCO','Meitner Ring','Orca','2015-03-04 19:50:35'
'DIMOCO','Meitner Ring','Sidewinder','2015-03-04 19:50:35'
'DISO','Shifnalport','Hauler','2015-04-05 13:22:13'
'DISO','Shifnalport','Sidewinder','2015-04-05 13:21:54'
'DISO','Shifnalport','Type 9','2015-04-05 13:22:13'
'DJAUJAS','Von Krusenstern Enterprise','Adder','2015-03-04 19:50:35'
'DJAUJAS','Von Krusenstern Enterprise','Cobra','2015-03-04 19:50:35'
'DJAUJAS','Von Krusenstern Enterprise','Eagle','2015-03-04 19:50:35'
Expand Down Expand Up @@ -605,6 +620,14 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'G 240-11','Walker Hub','Type 6','2015-03-04 22:47:14'
'G 240-11','Walker Hub','Type 9','2015-03-04 22:47:14'
'G 240-11','Walker Hub','Viper','2015-03-04 22:47:14'
'GABIETYE','Holberg Terminal','Adder','2015-04-06 06:39:08'
'GABIETYE','Holberg Terminal','Cobra','2015-04-06 06:39:08'
'GABIETYE','Holberg Terminal','Dropship','2015-04-06 06:39:08'
'GABIETYE','Holberg Terminal','Hauler','2015-04-06 06:39:09'
'GABIETYE','Holberg Terminal','Sidewinder','2015-04-06 06:39:09'
'GABIETYE','Holberg Terminal','Type 6','2015-04-06 06:39:09'
'GABIETYE','Holberg Terminal','Type 7','2015-04-06 06:39:09'
'GABIETYE','Holberg Terminal','Type 9','2015-04-06 06:39:09'
'GD 140','Liwei Terminal','Adder','2015-03-04 19:50:35'
'GD 140','Liwei Terminal','Anaconda','2015-03-04 19:50:35'
'GD 140','Liwei Terminal','Asp','2015-03-04 19:50:35'
Expand Down Expand Up @@ -740,6 +763,12 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'HIP 88617','Stephenson Station','Eagle','2015-03-27 20:23:05'
'HIP 88617','Stephenson Station','Orca','2015-03-27 20:23:11'
'HIP 88617','Stephenson Station','Sidewinder','2015-03-27 20:22:58'
'HIP 9216','Goldreich Orbital','Adder','2015-04-04 22:15:11'
'HIP 9216','Goldreich Orbital','Cobra','2015-04-04 22:15:11'
'HIP 9216','Goldreich Orbital','Eagle','2015-04-04 22:15:11'
'HIP 9216','Goldreich Orbital','Hauler','2015-04-04 22:15:11'
'HIP 9216','Goldreich Orbital','Sidewinder','2015-04-04 22:15:11'
'HIP 9216','Goldreich Orbital','Type 6','2015-04-04 22:15:11'
'HOLIACAN','Melbourne','Adder','2015-03-26 10:03:59'
'HOLIACAN','Melbourne','Cobra','2015-03-26 10:03:59'
'HOLIACAN','Melbourne','Eagle','2015-03-26 10:03:59'
Expand Down Expand Up @@ -829,6 +858,12 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'IGAL','Qushji Orbital','Eagle','2015-03-12 12:04:43'
'IGAL','Qushji Orbital','Sidewinder','2015-03-12 12:04:43'
'IGAL','Qushji Orbital','Type 6','2015-03-12 12:04:43'
'INMUTHA','Bujold Orbital','Cobra','2015-04-06 06:07:39'
'INMUTHA','Bujold Orbital','Eagle','2015-04-06 06:07:39'
'INMUTHA','Bujold Orbital','Hauler','2015-04-06 06:07:39'
'INMUTHA','Bujold Orbital','Sidewinder','2015-04-06 06:07:39'
'INMUTHA','Bujold Orbital','Type 6','2015-04-06 06:07:39'
'INMUTHA','Bujold Orbital','Type 7','2015-04-06 06:07:39'
'IOTA PERSEI','Walker City','Adder','2015-03-04 19:50:35'
'IOTA PERSEI','Walker City','Anaconda','2015-03-04 19:50:35'
'IOTA PERSEI','Walker City','Asp','2015-03-04 19:50:35'
Expand Down Expand Up @@ -949,6 +984,12 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'KOKOJINA','Ali Ring','Type 9','2015-03-20 19:59:30'
'KOKOJINA','Ali Ring','Viper','2015-03-20 19:59:30'
'KOKOJINA','Ali Ring','Vulture','2015-03-20 19:59:30'
'KONGKOMISSO','Glenn Horizons','Dropship','2015-04-06 03:55:00'
'KONGKOMISSO','Glenn Horizons','Hauler','2015-04-06 03:55:00'
'KONGKOMISSO','Glenn Horizons','Python','2015-04-06 03:55:00'
'KONGKOMISSO','Glenn Horizons','Sidewinder','2015-04-06 03:55:00'
'KONGKOMISSO','Glenn Horizons','Type 6','2015-04-06 03:55:00'
'KONGKOMISSO','Glenn Horizons','Viper','2015-04-06 03:55:00'
'KRUGER 60','Kepler Gateway','Cobra','2015-03-04 19:50:35'
'KRUGER 60','Kepler Gateway','Dropship','2015-03-04 19:50:35'
'KRUGER 60','Kepler Gateway','Eagle','2015-03-04 19:50:35'
Expand Down Expand Up @@ -1048,6 +1089,9 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'LHANGKAMBE','Yeliseyev Terminal','Hauler','2015-03-04 19:50:35'
'LHANGKAMBE','Yeliseyev Terminal','Sidewinder','2015-03-04 19:50:35'
'LHANGKAMBE','Yeliseyev Terminal','Viper','2015-03-04 19:50:35'
'LHS 1110','Brill Ring','Cobra','2015-04-06 00:07:37'
'LHS 1110','Brill Ring','Type 6','2015-04-06 00:07:37'
'LHS 1110','Brill Ring','Type 7','2015-04-06 00:07:37'
'LHS 115','Aleksandrov Gateway','Anaconda','2015-03-04 19:50:35'
'LHS 115','Aleksandrov Gateway','Asp','2015-03-04 19:50:35'
'LHS 115','Aleksandrov Gateway','Cobra','2015-03-04 19:50:35'
Expand Down Expand Up @@ -1313,6 +1357,19 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'LTT 9552','Reichelt Orbital','Type 6','2015-03-23 22:56:40'
'LTT 9552','Reichelt Orbital','Type 7','2015-03-23 22:56:40'
'LTT 9552','Reichelt Orbital','Type 9','2015-03-23 22:56:40'
'LTT 9605','Dalgarno City','Adder','2015-04-06 06:20:09'
'LTT 9605','Dalgarno City','Cobra','2015-04-06 06:20:09'
'LTT 9605','Dalgarno City','Hauler','2015-04-06 06:20:09'
'LTT 9605','Dalgarno City','Python','2015-04-06 06:20:10'
'LTT 9605','Dalgarno City','Sidewinder','2015-04-06 06:19:27'
'LTT 9605','Dalgarno City','Type 6','2015-04-06 06:20:10'
'LTT 9605','Dalgarno City','Type 9','2015-04-06 06:20:10'
'LTT 9605','Dalgarno City','Viper','2015-04-06 06:20:09'
'LTT 9605','Laurent Terminal','Adder','2015-04-06 05:50:11'
'LTT 9605','Laurent Terminal','Eagle','2015-04-06 05:50:11'
'LTT 9605','Laurent Terminal','Hauler','2015-04-06 05:50:11'
'LTT 9605','Laurent Terminal','Sidewinder','2015-04-06 05:49:53'
'LTT 9605','Laurent Terminal','Viper','2015-04-06 05:50:11'
'LTT 9863','Lynden-Bell Terminal','Asp','2015-03-29 20:58:38'
'LTT 9863','Lynden-Bell Terminal','Eagle','2015-03-29 20:58:38'
'LTT 9863','Lynden-Bell Terminal','Hauler','2015-03-29 20:58:10'
Expand Down Expand Up @@ -1388,6 +1445,37 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'MEENATES','Comino Station','Type 9','2015-03-20 19:34:58'
'MEENATES','Glazkov Station','Eagle','2015-03-20 20:06:05'
'MEENATES','Glazkov Station','Sidewinder','2015-03-20 20:05:58'
'MEGREZ','Clement Terminal','Adder','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Cobra','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Hauler','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Python','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Sidewinder','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Type 6','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Type 9','2015-04-01 11:06:49'
'MEGREZ','Clement Terminal','Viper','2015-04-01 11:06:49'
'MEGREZ','Godel Dock','Asp','2015-04-01 10:38:42'
'MEGREZ','Godel Dock','Cobra','2015-04-01 10:38:42'
'MEGREZ','Godel Dock','Hauler','2015-04-01 10:38:42'
'MEGREZ','Godel Dock','Sidewinder','2015-04-01 10:38:42'
'MEGREZ','Godel Dock','Type 6','2015-04-01 10:38:42'
'MEGREZ','Godel Dock','Type 9','2015-04-01 10:38:42'
'MEGREZ','Hudson Enterprise','Adder','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Cobra','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Hauler','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Python','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Sidewinder','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Type 6','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Type 9','2015-04-01 10:56:33'
'MEGREZ','Hudson Enterprise','Viper','2015-04-01 10:56:33'
'MEGREZ','Panshin Terminal','Adder','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Asp','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Cobra','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Hauler','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Python','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Sidewinder','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Type 6','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Type 9','2015-04-01 10:48:10'
'MEGREZ','Panshin Terminal','Viper','2015-04-01 10:48:10'
'MEINJHALARA','Fremont Port','Adder','2015-03-04 19:50:35'
'MEINJHALARA','Fremont Port','Anaconda','2015-03-04 19:50:35'
'MEINJHALARA','Fremont Port','Asp','2015-03-04 19:50:35'
Expand Down Expand Up @@ -1524,6 +1612,14 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'NUNGAMICI','Thiele Port','Hauler','2015-03-03 01:00:00'
'NUNGAMICI','Thiele Port','Sidewinder','2015-03-03 01:00:00'
'NUNGAMICI','Thiele Port','Type 7','2015-03-03 01:00:00'
'NUNUS','Antoniadi Port','Asp','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Eagle','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Fer-de-Lance','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Hauler','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Sidewinder','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Type 6','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Type 7','2015-04-05 23:16:36'
'NUNUS','Antoniadi Port','Type 9','2015-04-05 23:16:36'
'NYANKTONA','Mackellar Dock','Adder','2015-03-27 17:41:57'
'NYANKTONA','Mackellar Dock','Anaconda','2015-03-27 17:41:57'
'NYANKTONA','Mackellar Dock','Asp','2015-03-27 17:41:57'
Expand Down Expand Up @@ -1670,6 +1766,14 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'ROSS 1069','Viehbock City','Type 7','2015-03-04 19:50:35'
'ROSS 1069','Viehbock City','Type 9','2015-03-04 19:50:35'
'ROSS 1069','Viehbock City','Viper','2015-03-04 19:50:35'
'ROSS 209','Janes Terminal','Asp','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Dropship','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Eagle','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Hauler','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Sidewinder','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Type 7','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Viper','2015-04-06 01:02:00'
'ROSS 209','Janes Terminal','Vulture','2015-04-06 01:02:00'
'SALARHUL','Hiraga Gateway','Hauler','2015-03-22 18:44:21'
'SALARHUL','Hiraga Gateway','Sidewinder','2015-03-22 18:44:09'
'SALARHUL','Hiraga Gateway','Type 6','2015-03-22 18:44:27'
Expand Down Expand Up @@ -1794,6 +1898,11 @@ unq:[email protected]_id,unq:[email protected]_id,unq:[email protected]_id,mod
'TAUERNI','Rushworth Port','Sidewinder','2015-03-04 19:50:35'
'TAUERNI','Rushworth Port','Type 9','2015-03-04 19:50:35'
'TAUERNI','Rushworth Port','Viper','2015-03-04 19:50:35'
'TEAKA','Valdes Dock','Hauler','2015-04-06 03:00:56'
'TEAKA','Valdes Dock','Sidewinder','2015-04-06 03:00:56'
'TEAKA','Valdes Dock','Type 6','2015-04-06 03:00:56'
'TEAKA','Valdes Dock','Type 9','2015-04-06 03:00:56'
'TEAKA','Valdes Dock','Viper','2015-04-06 03:00:56'
'THIANSI','Worlidge Port','Cobra','2015-03-04 19:50:35'
'THIANSI','Worlidge Port','Dropship','2015-03-04 19:50:35'
'THIANSI','Worlidge Port','Eagle','2015-03-04 19:50:35'
Expand Down
Loading

0 comments on commit e6b00f1

Please sign in to comment.