Commit Graph
166 Commits
Author SHA1 Message Date
Athanasius ba68397b3f CAPI killswitches: endpoint killswitches & eddn export ones too
* Added `capi.request.<endpoint>` killswitches at appropriate call points.
* Added `eddn.capi_export.<type>` killswitches.  This allows for killing
  just the EDDN export of such CAPI-derived data, without stopping the actual
  queries, as other plugins/functionality might still have harmless use of
  the data.
* PLUGINS.md: Actually describe the contents of `data` passed to plugins, and
  point out it might not always contain market or shipyard data.  This is
  not only because of the new killswitches, but could already have happened
  if the station/port docked at didn't have the services.
* Some misc typing cleanups.
2022-12-16 15:06:01 +00:00
Athanasius e2f4f8f665 PLUGINS.md: Slightly improve CAPI Legacy/Live doc 2022-12-14 13:51:29 +00:00
Athanasius 605ad07aac Merge pull request #1747 from EDCD/enhancement/1728/capi-for-legacy
CAPI: Enable use of Legacy host when applicable.
2022-12-14 10:42:05 +00:00
Athanasius 84615db839 PLUGINS.md: Allow use of CAPIData.source_host
* Additional Allowed Imports `from companion ...`.

* Plugin authors will still need to chain `cmdr_data_legacy()` to calling
  `cmdr_data()`, but with sanctioned access to `data.source_host` they can
  then determine the galaxy data source.

* Re-worked the documentation for CAPI data a little to make all of this as
  clear as possible.
2022-12-08 13:17:13 +00:00
Athanasius af5d998464 PLUGINS.md: Correct the statement about python stdlib 2022-12-08 12:59:36 +00:00
Athanasius a3a52055d3 CAPI/PLUGINS.md: Document cmdr_data_legacy()
For now warn against trying to use extra CAPIData properties to determine
the galaxy.
2022-12-08 12:53:31 +00:00
Athanasius 3e15aa0fe6 PLUGINS.md: More fully document state['NavRoute'
This includes the "catching up" load of the data.
2022-12-06 15:42:59 +00:00
Athanasius b4c4e44cb7 eddn/CAPI: Use a common function for game_version strings
* This did, however, remind me that the `data` passed into `cmdr_data()`
  is an amalgam of `/profile`, `/market` and `/shipyard` queries.

  This means that the data.source_endpoint is **not correct for all of
  the data and its use**.  As such I had to pass 'hard coded' values into
  the function from the various CAPI export functions.  They know what it
  is they're exporting.

* As this reminded me that "CAPI `data` is actually a `CAPIDATA`", I've
  documented that in PLUGINS.md, but with a dire warning against relying on
  any of the extra properties.
2022-12-01 16:42:06 +00:00
Athanasius b06e579754 PLUGINS.md: Emphasise limited use of from config import config 2022-12-01 12:14:49 +00:00
Athanasius 0eb33e011b PLUGINS.md: Document new IsDocked state flag. 2022-11-23 15:57:25 +00:00
Athanasius fa834daaca PLUGINS.md: Fix example return type hint for journal_entry()
It's `Optional[str]` for possible error string being returned.
2022-08-15 08:39:34 +01:00
Athanasius 1bb0bf9f74 PLUGINS.md: Document NavRouteClear behaviour 2022-08-10 11:47:51 +01:00
Athanasius 7116964dba PLUGINS: Call out keeping an eye on Discussions 2022-02-17 12:19:36 +00:00
Athanasius 785f9a3235 PLUGINS.md: We don't currently include all of Python stdlib 2021-11-16 11:07:32 +00:00
Athanasius 945baf7f53 Merge branch 'stable' 2021-10-25 11:12:39 +01:00
Athanasius cf5806021e PLUGINS.md: capi_is_horizons() now 2021-10-18 12:33:11 +01:00
Chris 5e5169da51 Fix shutting_down example in plugins.md 2021-08-25 15:03:19 -04:00
Chris 705d2dd4f1 Fix game_runnning() doc in PLUGINS.md 2021-08-24 14:52:10 -04:00
Athanasius f977ad6716 PLUGINS.md: General PyCharm alerts pass
A few bits of example code tweaked to be more correct, but to make
PyCharm truly happy about the file we'd need to expand the examples to
stupid proportions (extra imports, indent changes etc).
2021-08-13 13:50:46 +01:00
Athanasius 6c34ceaba9 PLUGINS.md: s/EDMC/EDMarketConnector/ almost everywhere & reflow
The reflow is on *all* non-code/table text to be within 80 columns,
excepting if a link just makes that impossible.
2021-08-13 13:32:36 +01:00
Athanasius 411bd0edf2 journal/CQC: Minor documentation tweaks for language/grammar 2021-08-13 13:19:46 +01:00
norohind c65ef0a4d6 PLUGINS.md: deduplicate content table for state in journal_entry_cqc 2021-08-13 14:41:35 +03:00
norohind 29df3869cd PLUGINS.md: update first EDMC version with journal_entry_cqc 2021-08-13 14:15:46 +03:00
norohind 28f7a2b2fe PLUGINS.md: add ref link for systems to CQC maps mapping 2021-08-13 14:07:50 +03:00
norohind 30048ded88 PLUGINS.md: initial update for journal_entry_cqc 2021-08-11 17:47:06 +03:00
A_D 2e5e55af9a Applied requested changes 2021-06-20 17:44:29 +02:00
A_D f609545fdc Updated plugin docs 2021-06-18 23:36:45 +02:00
A_D fe0e752c9b Added support for arbitrary plugins for POST debug
This works by replacing --eddn-local with --debug-sender, and making the
webserver more generic. support has been added to EDSM, EDDN, and INARA.
2021-06-18 23:36:42 +02:00
Athanasius 937aaccec4 ShipLockerJSON: Ensure initialised, and document it. 2021-06-10 14:20:27 +01:00
Athanasius 13119b9509 Release 5.1.0: *not* 5.0.5. We want the Minor bump. 2021-06-04 14:02:59 +01:00
Athanasius 7a7bd7036b PLUGINS: Added 'New in 5.0.5' section 2021-06-04 13:41:03 +01:00
A_D 0ecd33c013 Documented new monitor.state values 2021-06-04 13:47:29 +02:00
Athanasius b11486c64c PLUGINS.md: Document new language/gameversion/gamebuild state fields. 2021-05-27 13:57:28 +01:00
Athanasius f46618b61c Suits: Added German localisations/short forms for names. 2021-05-26 14:49:17 +01:00
Athanasius bac718aeff Store Fileheader language, gameversion and build in monitor.state 2021-05-25 17:56:11 +01:00
Athanasius 143a205fb9 Backpack: event name is CamelCase, stored in monitor.state, doc
* Surprise!  The new event is `BackPack`, not `Backpack`, although the
  filename *is* `Backpack.json`.
* Store the loaded JSON dict in `monitor.state['BackpackJSON']`.  That
  `p` is lower case to match with the filename, not the event name.
* Document this in PLUGINS.md.

Unless EDSM is telling us to discard this we should now be sending it.
2021-05-20 18:13:51 +01:00
Athanasius 9c4058da60 PLUGINS.md: Actually have something in Avoiding pitfalls about dir name 2021-05-18 23:21:05 +01:00
Athanasius 6448d03ab3 PLUGINS.md: Document packaging extra modules 2021-05-18 23:18:30 +01:00
Athanasius d850fa050e PLUGINS.md: Document Horizons and Odyssey state booleans 2021-05-17 14:53:36 +01:00
Athanasius f8e562eed2 PLUGINS.md: Do NOT tempt devs into using monitor.state directly. 2021-05-17 13:03:10 +01:00
Athanasius b444647c4a PLUGINS: Explicitly outline how to be informed of all releases. 2021-05-12 22:47:36 +01:00
Athanasius b3495df1b6 PLUGINS: Tweak config.appversion section 2021-05-12 09:53:44 +01:00
Athanasius 41adf596ce PLUGINS/config: Better forwards-compatibility example 2021-05-11 22:46:39 +01:00
Athanasius 682c48e5ac PLUGINS: Document better config forwards compatibility code 2021-05-11 21:48:03 +01:00
Athanasius 1b7f5e2b06 PLUGINS.md: Document config methods workaround for <5.0.0 2021-05-11 08:32:07 +01:00
Athanasius 63a0456a9f PLUGINS.md: Fix Flags to reference edmc_data, not plug. 2021-05-09 10:32:58 +01:00
Athanasius d475d3194f PLUGINS.md: Document extra python modules we package for plugins use. 2021-05-06 11:09:49 +01:00
Athanasius bd1b86d3a3 Suits/Loadouts: Always convert to dict form for simpler downstream code. 2021-04-29 11:30:55 +01:00
Athanasius eb04673751 PLUGINS.md: Document dual-type of Suits, and helper functions. 2021-04-19 12:30:24 +01:00
Athanasius 29473de031 PLUGINS.md: Update for all added Odyssey monitor.state fields 2021-04-13 12:26:33 +01:00