Skip to content

Drop python 3.9#1649

Open
amilcarlucas wants to merge 6 commits into
masterfrom
drop_python_3.9
Open

Drop python 3.9#1649
amilcarlucas wants to merge 6 commits into
masterfrom
drop_python_3.9

Conversation

@amilcarlucas
Copy link
Copy Markdown
Collaborator

Description

Drop python 3.9 as it is EOL

Checklist

  • Run pre-commit checks locally
  • Verified by a human programmer
  • All commits are signed off (use git commit --signoff)
  • Code follows our coding standards
  • Documentation updated if needed
  • No breaking changes or properly documented

Testing

Describe how you tested these changes:

  • Unit tests pass
  • Integration tests pass
  • Manual testing performed
  • Tested on flight controller hardware

Copilot AI review requested due to automatic review settings May 27, 2026 19:07
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 28, 2026

☂️ Code Coverage

current status: ✅

Overall Coverage

Statements Covered Coverage Threshold Status
13151 12410 94% 89% 🟢

New Files

No new covered files...

Modified Files

File Coverage Status
ardupilot_methodic_configurator/main.py 89% 🟢
ardupilot_methodic_configurator/annotate_params.py 87% 🟢
ardupilot_methodic_configurator/argparse_check_range.py 100% 🟢
ardupilot_methodic_configurator/backend_filesystem.py 92% 🟢
ardupilot_methodic_configurator/backend_filesystem_configuration_steps.py 94% 🟢
ardupilot_methodic_configurator/backend_filesystem_freedesktop.py 98% 🟢
ardupilot_methodic_configurator/backend_filesystem_json_with_schema.py 91% 🟢
ardupilot_methodic_configurator/backend_filesystem_program_settings.py 97% 🟢
ardupilot_methodic_configurator/backend_filesystem_vehicle_components.py 94% 🟢
ardupilot_methodic_configurator/backend_flightcontroller.py 99% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_business_logic.py 100% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_commands.py 100% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_connection.py 100% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_factory_mavftp.py 100% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_factory_mavlink.py 100% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_files.py 98% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_params.py 100% 🟢
ardupilot_methodic_configurator/backend_flightcontroller_protocols.py 100% 🟢
ardupilot_methodic_configurator/backend_internet.py 90% 🟢
ardupilot_methodic_configurator/backend_safe_file_io.py 100% 🟢
ardupilot_methodic_configurator/battery_cell_voltages.py 100% 🟢
ardupilot_methodic_configurator/data_model_ardupilot_parameter.py 100% 🟢
ardupilot_methodic_configurator/data_model_battery_monitor.py 100% 🟢
ardupilot_methodic_configurator/data_model_configuration_step.py 100% 🟢
ardupilot_methodic_configurator/data_model_flightcontroller_info.py 100% 🟢
ardupilot_methodic_configurator/data_model_motor_test.py 100% 🟢
ardupilot_methodic_configurator/data_model_par_dict.py 100% 🟢
ardupilot_methodic_configurator/data_model_parameter_editor.py 83% 🟢
ardupilot_methodic_configurator/data_model_recent_items_history_list.py 100% 🟢
ardupilot_methodic_configurator/data_model_safe_evaluator.py 100% 🟢
ardupilot_methodic_configurator/data_model_software_updates.py 100% 🟢
ardupilot_methodic_configurator/data_model_vehicle_components_base.py 100% 🟢
ardupilot_methodic_configurator/data_model_vehicle_components_display.py 100% 🟢
ardupilot_methodic_configurator/data_model_vehicle_components_import.py 98% 🟢
ardupilot_methodic_configurator/data_model_vehicle_components_validation.py 98% 🟢
ardupilot_methodic_configurator/data_model_vehicle_project.py 98% 🟢
ardupilot_methodic_configurator/data_model_vehicle_project_creator.py 100% 🟢
ardupilot_methodic_configurator/extract_param_defaults.py 95% 🟢
ardupilot_methodic_configurator/frontend_tkinter_about_popup_window.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_autoresize_combobox.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_base_window.py 99% 🟢
ardupilot_methodic_configurator/frontend_tkinter_battery_monitor.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_component_editor.py 93% 🟢
ardupilot_methodic_configurator/frontend_tkinter_component_editor_base.py 92% 🟢
ardupilot_methodic_configurator/frontend_tkinter_component_template_manager.py 89% 🟢
ardupilot_methodic_configurator/frontend_tkinter_connection_selection.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_directory_selection.py 99% 🟢
ardupilot_methodic_configurator/frontend_tkinter_entry_dynamic.py 94% 🟢
ardupilot_methodic_configurator/frontend_tkinter_flightcontroller_connection_progress.py 97% 🟢
ardupilot_methodic_configurator/frontend_tkinter_flightcontroller_info.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_font.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_motor_test.py 90% 🟢
ardupilot_methodic_configurator/frontend_tkinter_pair_tuple_combobox.py 93% 🟢
ardupilot_methodic_configurator/frontend_tkinter_parameter_editor.py 97% 🟢
ardupilot_methodic_configurator/frontend_tkinter_parameter_editor_table.py 76% 🟢
ardupilot_methodic_configurator/frontend_tkinter_project_creator.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_rich_text.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_show.py 90% 🟢
ardupilot_methodic_configurator/frontend_tkinter_software_update.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_stage_progress.py 99% 🟢
ardupilot_methodic_configurator/frontend_tkinter_template_overview.py 100% 🟢
ardupilot_methodic_configurator/frontend_tkinter_usage_popup_window.py 90% 🟢
ardupilot_methodic_configurator/frontend_tkinter_usage_popup_windows.py 98% 🟢
ardupilot_methodic_configurator/internationalization.py 100% 🟢
ardupilot_methodic_configurator/param_pid_adjustment_update.py 94% 🟢
ardupilot_methodic_configurator/plugin_factory.py 100% 🟢
TOTAL 97% 🟢

updated for commit: 4b979e2 by action🐍

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 28, 2026

Test Results

     4 files       4 suites   42m 14s ⏱️
 4 042 tests  4 031 ✅  7 💤 4 ❌
15 960 runs  15 910 ✅ 46 💤 4 ❌

For more details on these failures, see this check.

Results for commit 4b979e2.

♻️ This comment has been updated with latest results.

@amilcarlucas amilcarlucas force-pushed the drop_python_3.9 branch 2 times, most recently from c2a7c13 to bc1ad8c Compare June 7, 2026 13:13
@amilcarlucas amilcarlucas requested a review from Copilot June 7, 2026 13:14
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 107 out of 107 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

scripts/generate_pdef.xml_metadata.py:53

  • importlib.util.find_spec() expects a module name (e.g., lxml), but package includes a version specifier (lxml==6.1.1), so this check will always fail and will always attempt to reinstall the dependency.

Comment thread test_pip_package.sh Outdated
rm -Rf build dist/ ardupilot_methodic_configurator.egg-info/

uv venv --python 3.12
uv venv --python 3.12 .venv-3.12
@amilcarlucas amilcarlucas force-pushed the drop_python_3.9 branch 2 times, most recently from aa9b4d6 to 42be790 Compare June 7, 2026 14:20
amilcarlucas and others added 6 commits June 7, 2026 17:10
Bumps [mypy](https://github.com/python/mypy) from 1.18.2 to 1.19.1.
- [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md)
- [Commits](python/mypy@v1.18.2...v1.19.1)

---
updated-dependencies:
- dependency-name: mypy
  dependency-version: 1.19.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
BREAKING CHANGE: Python 3.9 is EOL and no longer supported.

- Update requires-python to >=3.10 in pyproject.toml
- Remove Python 3.9 classifier and 3.9-only matplotlib dependency
- Set ruff target-version to py310
- Update CI matrix minimum version from 3.9 to 3.10 (pytest, pylint, pyright workflows)
- Modernize 512 typing annotations: Optional[X]?X|None, Union[X,Y]?X|Y
- Remove redundant Optional/Union imports from typing module
- Update test asserting UnionType origin to use types.UnionType instead of typing.Unionfix tests
…et_selected_key

Tcl 9.0 (bundled with uv standalone Python 3.10) changed the behavior of
ttk.Combobox.current(): when no item is selected it now returns "" (empty
string) instead of -1. The old guard `if i_index < 0` cannot handle this
because `self.tk.getint("")` raises TclError before the comparison is
reached, silently killing Tkinter event callbacks.

The broken callbacks left the ESC->FC protocol combobox entries in a stale
state (showing all options instead of the protocol-filtered subset), causing
four GUI integration tests to fail only on the Python 3.10 CI job:
- test_cascade_2_fc_esc_protocol_change_to_dshot150_expands_telem_type_widget_entries
- test_cascade_2_fc_esc_protocol_change_to_brushed_restricts_telem_type_widget_to_none
- test_cascade_3_telem_type_change_from_none_to_main_out_shows_bdshot_protocol_in_widget
- test_cascade_3_telem_type_change_from_none_to_serial_updates_protocol_widget

Fix get_selected_key() to catch TypeError (raised by the comparison on "")
and also guard explicitly against None/"" before the `< 0` check, so the
method safely returns None under both Tcl 8.6 and Tcl 9.0.

Signed-off-by: Amilcar do Carmo Lucas <amilcar.lucas@iav.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants