7
mirror of https://gitlab.com/kicad/code/kicad.git synced 2025-03-30 01:56:58 +00:00
Commit Graph

229 Commits

Author SHA1 Message Date
Jon Evans
3bdf82aea7 Python: switch to arg arrays for launch
Fixes Python when there are spaces in interpreter path
2025-02-11 12:14:25 -05:00
Jon Evans
290dc417d9 API: Change macOS raise mechanism
Other mechanism didn't work universally
2025-02-10 17:55:24 -05:00
Jon Evans
66cbc8127b Use open to launch actions on macOS
Fixes https://gitlab.com/kicad/code/kicad/-/issues/19859
2025-02-07 20:40:24 -05:00
Jon Evans
37d0d5f118 Use PYTHON_MANAGER to launch actions and capture trace output 2025-01-11 11:47:08 -05:00
Jon Evans
30d43c30b7 Prefer using pythonw on Windows 2025-01-10 22:41:35 -05:00
Jon Evans
eb4220bd29 Use an exception formatting function that works in Python <3.10 2025-01-10 21:46:50 -05:00
John Beard
51606e80d5 Scripting: a little bit more detail when failing to get wxPython version info
Print:

* the returned wx version string
* the Python sys version string, which can be a good pointer if the
  wrong interpreter has been picked up by the PyBind11 Cmake
* Exception output if any
2025-01-08 20:23:31 +08:00
Seth Hillbrand
074e6df3bc Revert "Move thread pool to singleton class"
This reverts commit 361f61a023.
2025-01-03 21:22:44 -08:00
Jon Evans
1a1120435f Rework how Python processes are launched
Fixes https://gitlab.com/kicad/code/kicad/-/issues/19465
2025-01-03 17:21:03 -05:00
Seth Hillbrand
361f61a023 Move thread pool to singleton class
Having thread pool as its own singleton in the library meant that each
kiface had its own threadpool, leading to many multiples of the threads
being started.  Placing a singleton class in PGM_BASE ensures that all
kifaces use the same thread pool.

The singleton class can be extended to provide single instance
guarantee for any element across kifaces
2025-01-03 13:51:11 -08:00
Jon Evans
89a50a3dcf Fix some issues calling Python on Windows systems 2025-01-02 22:45:24 -05:00
Jon Evans
40929d2482 Undo accidental commenting out of some Python search code 2025-01-02 17:31:42 -05:00
Seth Hillbrand
0b2d4d4879 Revise Copyright statement to align with TLF
Recommendation is to avoid using the year nomenclature as this
information is already encoded in the git repo.  Avoids needing to
repeatly update.

Also updates AUTHORS.txt from current repo with contributor names
2025-01-01 14:12:04 -08:00
John Beard
84c7a1e82d Fix Python search on Linux 2025-01-02 00:42:31 +08:00
Jon Evans
34dad3aa79 Implement searching for Python on Windows 2025-01-01 11:32:41 -05:00
Jon Evans
feca4176c0 Prefer some built-in paths for Python interpreter 2025-01-01 11:08:27 -05:00
Jon Evans
3bc190e515 Add deprecation notices to SWIG API 2024-12-30 11:25:04 -05:00
Jon Evans
d83e6326a5 API: Normalize paths to Python interpreter 2024-12-20 17:16:05 -05:00
Jon Evans
9eda526871 API: Show API actions alongside SWIG action plugins in preferences 2024-12-14 18:00:07 -05:00
Jeff Young
0bcf6000a4 Formatting. 2024-12-08 21:46:54 +00:00
Alex Shvartzkop
cf7ad330e9 Fix some platform ifdef checks. 2024-06-01 06:49:11 +03:00
Jon Evans
1dbe78c68b Add QA tests and expand serialization for API 2024-04-02 19:51:18 -04:00
Jon Evans
a3b6ab48a4 Add a new plugin system for the new API 2024-04-02 19:51:16 -04:00
Jon Evans
f613cd1cb4 ADDED: A new IPC API based on protobuf and nng
Details, documentation, and language bindings are works in
progress and will be evolving over the course of KiCad 9
development.
2024-04-02 19:34:36 -04:00
Roberto Fernandez Bautista
9957c58c14 Remove unused function RunPythonMethodWithReturnedString
pcbnewRunPythonMethodWithReturnedString already exists
2024-03-30 15:23:14 +01:00
Marek Roszko
46e301cd7f Add missing header include that only fails on msys2 ucrt
Weird
2024-03-21 07:41:51 -04:00
Marek Roszko
83ef5fd7d6 Move PGM_BASE to kicommon 2024-03-20 23:29:42 -04:00
Jeff Young
9ff66d0e71 Don't capture references to local variables for CallAfter.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/16934

(cherry picked from commit 9d40374baf)
2024-02-23 16:53:30 +01:00
Jon Evans
7b0bb59b37 Remove hard-coded versioned env vars in most places 2024-02-15 15:31:08 +00:00
Jeff Young
7cc663ad77 Schematic parity checking for CLI DRC. 2024-02-02 23:05:37 +00:00
Marek Roszko
5c20c5732d We don't need pgm_base to expose pybind to everything 2023-12-25 23:28:33 -05:00
Marek Roszko
34a51d3c21 Make wxPython work under run from build directory on macOS 2023-11-14 07:14:13 -05:00
Marek Roszko
e5f1cfd2b2 Set PYTHONPATH internally for macOS run from build dir 2023-11-13 23:09:12 -05:00
Jon Evans
d371bb06ae New macOS installation scripts
Replaces BundleUtilities that got broken by recent updates
and is basically unmaintained by cmake.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/15376
2023-09-19 17:23:30 -04:00
Marek Roszko
11de95778b Unwrap the FROM_UTF8 macro in favor of direct function
The extern just gets annoying to try to export the func later. We also yeet TO_UTF8 to string_utils.h for parity.
2023-09-09 00:10:57 -04:00
Nimish Telang
51e55dd750 Convert sprintf to snprintf in most files 2023-04-17 15:39:34 +00:00
Ian McInerney
a6ebd60c3b CMake: Modernize Boost import to use imported targets 2023-03-10 16:38:35 +00:00
aris-kimi
22bca5c2a0 Disable link maps by default and fix compile issue with lld linker
The link maps were actually disabled by default before
912f1d5cec, and required KICAD_MAKE_LINK_MAPS
to be provided to enable them. So switch back to disabling them by
default.

Also, The lld linker is unable to accept a single dash cref option, while
ld and gold can. Instead, use the double dash version that is supported
by all three.

xref: https://github.com/llvm/llvm-project/issues/60932

Co-authored-by: aris-kimi <aris_kimi@hotmail.com>
Co-authored-by: Ian McInerney <ian.s.mcinerney@ieee.org>
2023-02-22 23:18:36 +00:00
Ian McInerney
912f1d5cec Modernize setting link map linker flags 2023-02-22 01:44:06 +00:00
Ian McInerney
2b1040ae67 Fix compatibility with older wx versions
ToInt was only added in wx 3.1.6 apparently, so for now make them long
types. Fixes bug introduced in 8ce0a84ca7.
2023-02-14 13:48:47 +00:00
Ian McInerney
1e8cc6855d Relax wxPython version mismatch check to major.minor
The previous version check failed when the version was even slightly
different, including on the revision field. Theoretically the ABI of the
wx minor versions in use should be the same, so this might work. On the
other hand, with wxPython it could break as well. YOLO.
2023-02-14 00:21:15 +00:00
Seth Hillbrand
a9ed47f06c Update KICAD6->KICAD7 2023-01-23 22:21:12 +00:00
Marek Roszko
0ff32d20cd wxS more things 2023-01-22 09:41:42 -05:00
Jon Evans
70ec2f990f Work around wxPython / wxPropertyGrid fighting over global state
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13280
2023-01-21 17:06:51 -05:00
Stefan
2449f209b1 python version check: fix error message edge case 2023-01-02 20:20:01 +00:00
Jon Evans
5067e82e06 Only run the wxPython version check once 2023-01-02 13:26:55 -05:00
Jon Evans
af0b176f57 Just catch any Python exception, we don't care what it is.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13354
2023-01-02 13:06:20 -05:00
Jon Evans
f4a80903f0 Attempt to handle more edge cases in wxPython version check
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13354
2023-01-02 12:58:49 -05:00
Jon Evans
0a044656e3 Disable scripting and warn when wxPython version doesn't match 2023-01-02 11:52:14 -05:00
Jeff Young
66208b0ac0 Silence "menu item ID of 0 doesn't work on Mac" assert. 2022-12-30 22:59:08 +00:00