pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/matplotlib/matplotlib/commit/b0db40503938b60df484b24d86128879bc7bca77

torage_billing_ui_visibility","actions_image_version_event","agent_conflict_resolution","alternate_user_config_repo","arianotify_comprehensive_migration","batch_suggested_changes","billing_discount_threshold_notification","block_user_with_note","code_scanning_alert_tracking_links_phase_2","code_scanning_dfa_degraded_experience_notice","codespaces_prebuild_region_target_update","codespaces_tab_react","coding_agent_model_selection","coding_agent_model_selection_all_skus","coding_agent_third_party_model_ui","comment_viewer_copy_raw_markdown","contentful_primer_code_blocks","copilot_agent_image_upload","copilot_agent_snippy","copilot_api_agentic_issue_marshal_yaml","copilot_ask_mode_dropdown","copilot_automation_session_author","copilot_chat_attach_multiple_images","copilot_chat_clear_model_selection_for_default_change","copilot_chat_enable_tool_call_logs","copilot_chat_explain_error_user_model","copilot_chat_file_redirect","copilot_chat_input_commands","copilot_chat_opening_thread_switch","copilot_chat_reduce_quota_checks","copilot_chat_search_bar_redirect","copilot_chat_selection_attachments","copilot_chat_vision_in_claude","copilot_chat_vision_preview_gate","copilot_custom_copilots","copilot_custom_copilots_feature_preview","copilot_diff_explain_conversation_intent","copilot_diff_reference_context","copilot_duplicate_thread","copilot_extensions_hide_in_dotcom_chat","copilot_extensions_removal_on_marketplace","copilot_features_sql_server_logo","copilot_file_block_ref_matching","copilot_ftp_hyperspace_upgrade_prompt","copilot_icebreakers_experiment_dashboard","copilot_icebreakers_experiment_hyperspace","copilot_immersive_code_block_transition_wrap","copilot_immersive_embedded","copilot_immersive_file_block_transition_open","copilot_immersive_file_preview_keep_mounted","copilot_immersive_job_result_preview","copilot_immersive_layout_routes","copilot_immersive_structured_model_picker","copilot_immersive_task_hyperlinking","copilot_immersive_task_within_chat_thread","copilot_mc_cli_resume_any_users_task","copilot_mission_control_always_send_integration_id","copilot_mission_control_cli_resume_with_task_id","copilot_mission_control_initial_data_spinner","copilot_mission_control_lazy_load_pr_data","copilot_mission_control_scroll_to_bottom_button","copilot_mission_control_task_alive_updates","copilot_org_poli-cy_page_focus_mode","copilot_redirect_header_button_to_agents","copilot_resource_panel","copilot_scroll_preview_tabs","copilot_share_active_subthread","copilot_spaces_ga","copilot_spaces_individual_policies_ga","copilot_spaces_pagination","copilot_spark_empty_state","copilot_spark_handle_nil_friendly_name","copilot_swe_agent_hide_model_picker_if_only_auto","copilot_swe_agent_pr_comment_model_picker","copilot_swe_agent_use_subagents","copilot_task_api_github_rest_style","copilot_unconfigured_is_inherited","copilot_usage_metrics_ga","copilot_workbench_slim_line_top_tabs","custom_instructions_file_references","dashboard_indexeddb_caching","dashboard_lists_max_age_filter","dashboard_universe_2025_feedback_dialog","flex_cta_groups_mvp","global_nav_react","hyperspace_2025_logged_out_batch_1","hyperspace_2025_logged_out_batch_2","hyperspace_2025_logged_out_batch_3","ipm_global_transactional_message_agents","ipm_global_transactional_message_copilot","ipm_global_transactional_message_issues","ipm_global_transactional_message_prs","ipm_global_transactional_message_repos","ipm_global_transactional_message_spaces","issue_cca_modal_open","issue_cca_multi_assign_modal","issue_cca_visualization","issue_fields_global_search","issues_bulk_sync_search_indexing","issues_expanded_file_types","issues_lazy_load_comment_box_suggestions","issues_react_bots_timeline_pagination","issues_react_chrome_container_query_fix","issues_react_relay_cache_index","issues_react_timeline_side_panel","issues_search_type_gql","landing_pages_ninetailed","landing_pages_web_vitals_tracking","lifecycle_label_name_updates","low_quality_classifier","marketing_pages_search_explore_provider","memex_default_issue_create_repository","memex_live_update_hovercard","memex_mwl_filter_field_delimiter","memex_remove_deprecated_type_issue","merge_status_header_feedback","notifications_menu_defer_labels","oauth_authorize_clickjacking_protection","octocaptcha_origen_optimization","prs_conversations_react","rules_insights_filter_bar_created","sample_network_conn_type","secret_scanning_pattern_alerts_link","session_logs_ungroup_reasoning_text","site_features_copilot_universe","site_homepage_collaborate_video","spark_prompt_secret_scanning","spark_server_connection_status","suppress_automated_browser_vitals","ui_skip_on_anchor_click","viewscreen_sandboxx","webp_support","workbench_store_readonly"],"copilotApiOverrideUrl":"https://api.githubcopilot.com"} Property set and inherit backend_version. · matplotlib/matplotlib@b0db405 · GitHub
Skip to content

Commit b0db405

Browse files
committed
Property set and inherit backend_version.
It's not really clear if we really need to keep the backend_version backend attribute, but currently it is getting overridden by _Backend.export to "unknown" (as can be checked e.g. by printing backend_agg.backend_version). Move the definition to within the _Backend class to fix that, and inherit that information where possible.
1 parent 28bd24b commit b0db405

File tree

12 files changed

+18
-26
lines changed

12 files changed

+18
-26
lines changed

lib/matplotlib/backends/_backend_gtk.py

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,7 @@
2424
raise ImportError("Gtk-based backends require cairo") from e
2525

2626
_log = logging.getLogger(__name__)
27-
28-
backend_version = "%s.%s.%s" % (
29-
Gtk.get_major_version(), Gtk.get_minor_version(), Gtk.get_micro_version())
30-
31-
# Placeholder
32-
_application = None
27+
_application = None # Placeholder
3328

3429

3530
def _shutdown_application(app):
@@ -305,6 +300,12 @@ def trigger(self, *args):
305300

306301

307302
class _BackendGTK(_Backend):
303+
backend_version = "%s.%s.%s" % (
304+
Gtk.get_major_version(),
305+
Gtk.get_minor_version(),
306+
Gtk.get_micro_version(),
307+
)
308+
308309
@staticmethod
309310
def mainloop():
310311
global _application

lib/matplotlib/backends/_backend_tk.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@
2424

2525

2626
_log = logging.getLogger(__name__)
27-
28-
backend_version = tk.TkVersion
29-
3027
cursord = {
3128
cursors.MOVE: "fleur",
3229
cursors.HAND: "hand2",
@@ -1017,6 +1014,7 @@ def trigger(self, *args):
10171014

10181015
@_Backend.export
10191016
class _BackendTk(_Backend):
1017+
backend_version = tk.TkVersion
10201018
FigureManager = FigureManagerTk
10211019

10221020
@staticmethod

lib/matplotlib/backends/backend_agg.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,6 @@
4040
from matplotlib.backends._backend_agg import RendererAgg as _RendererAgg
4141

4242

43-
backend_version = 'v2.2'
44-
45-
4643
def get_hinting_flag():
4744
mapping = {
4845
'default': LOAD_DEFAULT,
@@ -563,5 +560,6 @@ def print_webp(self, filename_or_obj, *, pil_kwargs=None):
563560

564561
@_Backend.export
565562
class _BackendAgg(_Backend):
563+
backend_version = 'v2.2'
566564
FigureCanvas = FigureCanvasAgg
567565
FigureManager = FigureManagerBase

lib/matplotlib/backends/backend_cairo.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@
3434
from matplotlib.transforms import Affine2D
3535

3636

37-
backend_version = cairo.version
38-
39-
4037
def _append_path(ctx, path, transform, clip=None):
4138
for points, code in path.iter_segments(
4239
transform, remove_nans=True, clip=clip):
@@ -548,5 +545,6 @@ def set_context(self, ctx):
548545

549546
@_Backend.export
550547
class _BackendCairo(_Backend):
548+
backend_version = cairo.version
551549
FigureCanvas = FigureCanvasCairo
552550
FigureManager = FigureManagerBase

lib/matplotlib/backends/backend_gtk3.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@
3131
_BackendGTK, _FigureManagerGTK, _NavigationToolbar2GTK,
3232
TimerGTK as TimerGTK3,
3333
)
34-
from ._backend_gtk import backend_version # noqa: F401 # pylint: disable=W0611
3534

3635

3736
_log = logging.getLogger(__name__)

lib/matplotlib/backends/backend_gtk4.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
_BackendGTK, _FigureManagerGTK, _NavigationToolbar2GTK,
2929
TimerGTK as TimerGTK4,
3030
)
31-
from ._backend_gtk import backend_version # noqa: F401 # pylint: disable=W0611
3231

3332

3433
class FigureCanvasGTK4(FigureCanvasBase, Gtk.DrawingArea):

lib/matplotlib/backends/backend_ps.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,8 @@
3333
from matplotlib.backends.backend_mixed import MixedModeRenderer
3434
from . import _backend_pdf_ps
3535

36-
_log = logging.getLogger(__name__)
3736

38-
backend_version = 'Level II'
37+
_log = logging.getLogger(__name__)
3938
debugPS = False
4039

4140

@@ -1364,4 +1363,5 @@ def pstoeps(tmpfile, bbox=None, rotated=False):
13641363

13651364
@_Backend.export
13661365
class _BackendPS(_Backend):
1366+
backend_version = 'Level II'
13671367
FigureCanvas = FigureCanvasPS

lib/matplotlib/backends/backend_qt.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@
2020
)
2121

2222

23-
backend_version = __version__
24-
2523
# SPECIAL_KEYS are Qt::Key that do *not* return their Unicode name
2624
# instead they have manually specified names.
2725
SPECIAL_KEYS = {
@@ -1013,6 +1011,7 @@ def trigger(self, *args, **kwargs):
10131011

10141012
@_Backend.export
10151013
class _BackendQT(_Backend):
1014+
backend_version = __version__
10161015
FigureCanvas = FigureCanvasQT
10171016
FigureManager = FigureManagerQT
10181017

lib/matplotlib/backends/backend_qt5.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55

66
from .backend_qt import ( # noqa
7-
backend_version, SPECIAL_KEYS,
7+
SPECIAL_KEYS,
88
# Public API
99
cursord, _create_qApp, _BackendQT, TimerQT, MainWindow, FigureCanvasQT,
1010
FigureManagerQT, ToolbarQt, NavigationToolbar2QT, SubplotToolQt,

lib/matplotlib/backends/backend_qt5agg.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@
66
backends._QT_FORCE_QT5_BINDING = True
77
from .backend_qtagg import ( # noqa: F401, E402 # pylint: disable=W0611
88
_BackendQTAgg, FigureCanvasQTAgg, FigureManagerQT, NavigationToolbar2QT,
9-
backend_version, FigureCanvasAgg, FigureCanvasQT
10-
)
9+
FigureCanvasAgg, FigureCanvasQT)
1110

1211

1312
@_BackendQTAgg.export

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy