Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace deprecated use of CssProvider.load_from_data #2953

Merged
merged 1 commit into from
Dec 23, 2023
Merged

Conversation

amolenaar
Copy link
Member

@amolenaar amolenaar commented Dec 23, 2023

PR Type

What kind of change does this PR introduce?

  • Bug fix
  • Feature
  • Chore (refactoring, formatting, local variables, other cleanup)
  • Documentation content changes

What is the current behavior?

Gtk.CssProvider.load_from_data is deprecated in GTK 4.12:

gaphor/ui/tests/test_handletool.py::test_iconnect
  /Users/arjan/Development/gaphor/.venv/lib/python3.11/site-packages/gi/overrides/Gtk.py:1641: DeprecationWarning: Gtk.CssProvider.load_from_data is deprecated
    super(CssProvider, self).load_from_data(text, length)

Issue Number: #2231

What is the new behavior?

Replace by Gtk.CssProvider.load_from_string.

However, this API is introduced in GTK 4.12.

Does this PR introduce a breaking change?

  • Yes
  • No

GTK 4.12+ is required once this change is merged.

@github-actions github-actions bot added the python Pull requests that update Python code label Dec 23, 2023
Copy link
Member

@danyeaw danyeaw left a comment

Choose a reason for hiding this comment

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

Nice, one more down!

@danyeaw danyeaw added chore Maintenance related PR and removed python Pull requests that update Python code labels Dec 23, 2023
@danyeaw danyeaw merged commit 1f6c40f into main Dec 23, 2023
20 checks passed
@danyeaw danyeaw deleted the css-from-string branch December 23, 2023 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Maintenance related PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants