Re: Feedback from downstreams presentation from DX hackfest 2015

On Mon, 2015-02-02 at 12:19 +0100, Olav Vitters wrote:
On Mon, Feb 02, 2015 at 08:05:00AM +0000, Philip Withnall wrote:
It was suggested that I send the presentation to DDL, since it might be
of general interest. I haven’t modified it from the hackfest version, so
please let me know if you have any questions.

Can we assume that most still needs to be actioned? Also interested what
discussions there were during the hackfest to improving this. E.g.
Should we maybe reach out to our advisory board? Some things mentioned
lack of documentation. So with DX hackfest and documentation at same
time I also wonder if there were any possibilities to improve this.

Here’s my list of what has been done for each point, and what still
needs doing. Apologies for the messy list, but since a lot of points
have been filed as bugs already, there seems little point in writing
them up nicely. They should roughly correspond to the points in the
presentation, with duplicates removed. If anything’s unclear, please

The ‘TODO’ items I still need to follow up on, but there are some open
questions next to them (and a few other points). I’ll bring some of
those up on DDL in the near future, but any ideas people have about
fixing them are welcome any time.

SVGs in GtkImages don’t scale with the widget
Some properties are confusing, such as
Document GtkBuilder behaving like a factory
gtkmm documentation search in Devhelp
Documentation of widget event masks and event propagation is opaque
Deprecations should be documented with a rationale and replacement API,
and hopefully also a porting guide
Project bootstrapping
 • To be done in Builder
Bootstrapping problems with gettext, intltool, gtk-doc
 • To be done in Builder
Indicating licencing in files
 • Tartan bug 844/3c7
Knowing which files to put in git
 • To be done in Builder
Parallel installability of libraries
 • TODO: See if any other documentation/examples needs updating
Total confusion over LT versioning
 • Not sure there’s anything which can be done about this — ideas?
Namespacing confusion for GObject
 • (random assortment of related bugs which I will try and go through)
Encapsulation of members in GObject private structs
 • TODO: Write a HowDoI on subclassing?
Repeated, inefficient use of GList
 • TODO: Can we do more? Stop promoting linked lists somehow?
Confusion between sync, async and threads
    - Static analysis
    - Dynamic checking (warn if sync functions called in the main loop)
    - Documentation: hide sync functions unless explicitly asked for;
      maybe only show async functions in index, add link from them to
      sync functions to show that documentation
    - Documentation for best practices for structuring async calls?
Massive over-use of g_strdup()
Persistent confusion over g_free(NULL)
No compiler, GIR or gtk-doc warnings enabled
No gtk-doc tests enabled
Confusion over documentation generation with gdbus-codegen
Tests were not automatable
 • For example, some tests in the wild ask for user input, and print
   output rather than asserting it’s some known, expected value. The
   user is expected to check the output manually.
 • Not sure if there’s anything which can be done upstream to discourage
Tests were not hooked up to CI or other tooling
 • TODO: Somehow make GTest easier to hook up to CI? TAP support is a
   good step. What else can be done?
APIs were untestable by design
 • This arises from use of global resources, such as databases in the
   home directory, or system services, by code under test. The fix is to
   structure the code to allow those resources to be mocked up by the
   test fixture.
 • Not sure if there’s anything which can be done upstream to fix this.
JSON reader function pairing on different code paths
No validation of resource files (XML, JSON schemas)
 • TODO: Write a HowDoI on using GSettings
 • D-Bus introspection and bus config:
 • GtkBuilder:
 • GResource:
 • TODO: Write a HowDoI on using GResource
Confusion over GSettings schema internationalisation
Confusion over relocatable GSettings schemas
Confusion over GDBus vs. libdbus and libdbus-glib
 • dbus-glib documentation has had big deprecation warnings added:
 • Top google hits for ‘dbus-glib’ have been updated to mark it as
   completely deprecated
Poor D-Bus API design in places
Problems with D-Bus build system integration
Problems building SQL and SPARQL queries
 • SQLite: can’t think of a decent way of fixing this
Use of POSIX APIs incompatible with GLib
 • Tartan bug 844/b32
Reinvented thread pools
Implications on main contexts ignored
 • Maybe deprecate g_timeout_add, g_idle_add() (etc.) in favour of
   versions which take an explicit GMainContext? Just to prod the
   programmer into thinking about main contexts?
Problems building file paths
 • Lots of instances where g_strconcat() is used on UTF-8 strings and no
   encoding is performed.
 • Lots of cases where a path is built, then immediately passed to
   g_file_new_for_path() and freed again.
 • TODO: How about a g_file_new_build_path(varargs) function which takes
   UTF-8 components as varargs, converts them to the GLib filename
   encoding and effectively calls
   g_file_new_from_path(g_build_filename(converted_varargs)) on them?
No validation of file sandboxing
 • Is g_file_has_prefix() good enough for checking that a file is within
   a certain root? e.g. For checking that we’re saving a downloaded file
   to somewhere in ~/Downloads.


Attachment: signature.asc
Description: This is a digitally signed message part

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]