David Sangrey
dab510bb21
[PRE-RELEASE] .12.1-rc4
2024-10-01 18:23:06 -04:00
David Sangrey
ab02f49aba
[ #2303 ] Revert Prototyping for Protocol
2024-10-01 17:55:54 -04:00
David Sangrey
625856c31c
[1805] Apply More Pywin32
2024-06-11 11:36:43 -04:00
David Sangrey
571558daff
[1805] Additional Handover
2024-06-11 11:06:58 -04:00
David Sangrey
c14bd826d0
[Minor] Additional Visual Padding Fixes
2024-04-06 16:52:45 -04:00
David Sangrey
fbdc441390
[Minor] Return Visual Padding
...
Just makes it nicer to read.
2024-04-05 17:28:08 -04:00
David Sangrey
b5a4ee6ed2
[Nit] Cleanup some Flake8
2024-03-28 10:49:01 -04:00
David Sangrey
57cd75e75e
[2186] Additional Files
2024-03-27 19:39:51 -04:00
David Sangrey
4dd83f5fa4
[2051] And a few more, with timezones
2023-11-17 19:44:36 -05:00
Athanasius
7e6f3251bb
Merge pull request #1703 from EDCD/enhancement/64-bit
...
Make runnable under 64-bit Python
2022-12-30 16:57:29 +00:00
Athanasius
08d28c6f3d
protocol: Properly prototype GetMessageW & comment about 'exception'
...
* In trying to fix the return type 'exception' I first decided to properly
prototype GetMessageW().
* But it turns out that you just can't get rid of that exception, so I just
added a comment about it being harmless, because the functionality works
as intended anyway.
2022-12-23 16:41:07 +00:00
A_D
a930f5b902
protocol.py: Make mypy happy
...
This adds an assert that mypy will understand, and a type ignore because
it seems to ignore those asserts in imports
2022-12-23 18:25:14 +02:00
Athanasius
f141fccd86
protocol.py: Change definition of DefWindowProcW to work on 64-bit
...
Given this is the form of definition in the official Python docs I'm
wondering if this only ever worked on 32-bit by accident.
So, it was nothing to do with the type needing to be changed for 64-bit.
The error:
ctypes.ArgumentError: argument 4: <class 'OverflowError'>: int too long to convert
was a red herring in those terms.
2022-12-23 15:44:34 +00:00
Athanasius
0d2505ea48
protocol.py: mypy pass
...
* 'type: ignore' some ctypes operations on variables.
* Use `c_long(<value>)` on some returns. The ctypes types do work that way
as constructors.
* Fix the BAseHTTPHandler.log_request() types to match superclass.
2022-12-03 15:13:59 +00:00
Athanasius
bb2bf53647
protocol.py: flake8 pass
...
This is flake8 objecting to the "initialised later" `protocolhandler`.
2022-12-03 14:51:54 +00:00
A_D
5b68aad184
Remove protocol.protocolhandler singleton auto-init
...
In general, doing things like this on import is bad, but this was
changed specifically to remove a bug that causes
--force-localserver-auth to do nothing.
That is caused because while we were careful not to import protocol
until after we were done doing arg things, we did not check to make sure
something else didn't. Companion imports protocol, which thus always
instantiates WindowsProtocolHandler before we can modify some config
state to indicate that we want LinuxProtocolHandler.
2021-09-24 16:39:30 +02:00
Athanasius
305f8ca6b0
protocol.py: Use logger.trace_if(...)
2021-08-13 15:14:02 +01:00
Athanasius
9c95a11b8f
protocol.py: Fix minor typo in logging
2021-06-19 14:04:43 +01:00
Athanasius
cf1655894b
protocol: Pay attention to config.auth_force_edmc_protocol
2021-04-12 16:32:58 +01:00
Athanasius
efc3c9030d
protocol.py: Silence web server INFO if running without UI
...
Testing the outfitting.py changes brought this to light. I know, e.g.
TCE that uses EDMC.exe likes to have no extraneous output.
2021-04-12 08:31:48 +01:00
Athanasius
bc6557dd9c
Quieten various TRACE log output.
...
* A lot of this is commented out. It might be useful in the future, but
is just too noisy for now.
* Changed the protocol webserver to info, as it is.
* Left the EDSM 'not 1XX, 2XX or 5XX' in as it's a warning, so 'pass's
on the conditional bodies that would be empty now trace's are
commented.
2021-04-12 08:31:47 +01:00
Athanasius
740da49ce1
Add similar extra logging for localhost handler
...
* This also adjusts the logging in Session.auth_callback() because it
can be called from either protocol. Saying 'edmc://' there is
misleading.
2021-04-01 14:45:51 +01:00
Athanasius
baa86b4fbf
Add extra logging for Frontier Auth, especially via edmc://
2021-04-01 14:45:51 +01:00
Athanasius
1504f25d8f
protocol: Expand slightly on WNDCLASS with some references.
2021-04-01 14:45:49 +01:00
Athanasius
1692cac51c
protocol: docstring WNDCLASS structure
...
* Built with py2exe.
* Frontier Auth from scratch works on Windows 10 native.
2021-04-01 14:45:49 +01:00
Athanasius
165f55bba4
protocol: Work around incompatible types using conditional on wine_get_version
2021-04-01 14:45:49 +01:00
A_D
ceb2f74855
Final type annotation pass
2021-04-01 14:45:49 +01:00
A_D
adba94efa2
re-added appname import from constants
2021-04-01 14:45:49 +01:00
A_D
660878dcff
removed object
2021-04-01 14:45:49 +01:00
A_D
a55e43c0b5
Made linters happy
2021-04-01 14:45:49 +01:00
A_D
4e75941311
Made sure windll names are correct
...
A/W has meaning and should ALWAYS be noted
2021-04-01 14:45:49 +01:00
Athanasius
67d41d63dc
Added more comments to windows DDE
...
# Conflicts:
# protocol.py
2021-04-01 14:45:49 +01:00
A_D
96ac23a6eb
Made sure to use super() call
...
Assuming you know what your super is is a bad idea
2021-04-01 14:45:49 +01:00
A_D
1b0b482105
Replaced old formatting with fstring
2021-04-01 14:45:49 +01:00
A_D
d5670d9b08
Simplified GET response
2021-04-01 14:45:49 +01:00
Athanasius
65645ee224
Added docstrings
...
# Conflicts:
# protocol.py
2021-04-01 14:45:49 +01:00
A_D
4d7ec87746
Renamed ProtocolHandler implementations so not to clash
2021-04-01 14:45:49 +01:00
A_D
52494893e5
Refactored WindowProc callback
...
Who knew comments and a bit of explanation could help?
2021-04-01 14:45:49 +01:00
A_D
328f8c7397
Broke up giant if
2021-04-01 14:45:49 +01:00
A_D
d4cce9ee84
Removed * Imports
2021-04-01 14:45:49 +01:00
A_D
47d5dce6fe
Autoformatted code
2021-04-01 14:45:49 +01:00
Athanasius
64f090487e
Need from config import appname
else DDE ctypes code fails
2021-04-01 14:45:49 +01:00
Athanasius
2ec767405f
Move the 'duplicate' constants into a new constants.py
...
1. So now they're only defined in one place.
2. config.py does an import of them, and `from config import ...` then
chains through, so no need to update other users.
3. No need to ' # noqa E402' the killswitch/config imports now.
2021-04-01 14:45:48 +01:00
Athanasius
104f215732
protocol.py: Need from config import config
2021-04-01 14:45:48 +01:00
Athanasius
e7a7314c1a
protocol: Avoid Tk event_generate() calls during shutdown
...
# Conflicts:
# protocol.py
2021-04-01 14:45:48 +01:00
Athanasius
abfde73362
dashboard, hotkey, protocol: Use EDMCLogging.get_main_logger()
...
It does the EDMC/EDMarketConnector check.
2021-04-01 14:45:44 +01:00
Athanasius
c5a57e8a43
protocol.py: Log *end* of protocolhandler.close()
2021-04-01 14:45:44 +01:00
Athanasius
d5b2f32d18
protocol.py: Add logging to protocol shutdown sequence
...
# Conflicts:
# protocol.py
2021-04-01 14:45:44 +01:00
Athanasius
cc2395ca04
Add similar extra logging for localhost handler
...
* This also adjusts the logging in Session.auth_callback() because it
can be called from either protocol. Saying 'edmc://' there is
misleading.
2021-03-15 12:13:28 +00:00
Athanasius
4f524a0a35
Add extra logging for Frontier Auth, especially via edmc://
2021-03-15 12:07:39 +00:00