packages icon indicating copy to clipboard operation
packages copied to clipboard

[RFC] [cross_file] New architecture.

Open ditman opened this issue 1 year ago • 6 comments
trafficstars

This PR attempts to solve the current issues of XFile by slightly re-architecting it.

In this PR:

  • XFile is now an interface that does not have any code, except for the two "legacy" constructors that are maintained (but deprecated) for backwards-compatibility reasons.
  • Each underlying data structure contains a super simple implementation of the interface.
  • XFile instances are now created from the platform-specific (native vs web) factories.

This does not remove saveAs from the XFile interface.

[!NOTE] ~~This is a breaking change because I've made the old XFile constructors deprecated (and throwy) but if we want to, we could possibly re-implement the "old" constructors with the new implementations and a few conditional imports?~~

This is not a breaking change anymore. Old tests continue passing (test/legacy*), and new tests contain minor changes.

Anyway, just a RFC!

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

ditman avatar Sep 06 '24 02:09 ditman

/cc @stuartmorgan this is my idea for the "next" version of the x-files. PTAL and let me know what you think, or if you want this to go in another direction :)

The_Truth_Is_Out_There_tagline

ditman avatar Sep 06 '24 02:09 ditman

Quick note to say I haven't forgotten about this, I just haven't had time to fully context switch to give this the attention it will need. I'll try to do it within the next week.

stuartmorgan-g avatar Sep 18 '24 18:09 stuartmorgan-g

I'm going to work on this on my next flutter/packages on-call rotation.

ditman avatar Jan 15 '25 01:01 ditman

Hey @ditman! Greetings from stale PR triage. :) Do you plan to pick this back up?

Piinks avatar Mar 19 '25 22:03 Piinks

@Piinks I do want to pick this up again, but I don't think I'll have time to do this before I/O :(

ditman avatar Mar 27 '25 03:03 ditman

sorry @ditman to bother you but do you plan on finishing this PR

Coinners avatar Jul 01 '25 18:07 Coinners

Hey @ditman! Greetings from stale PR triage (again). Should we continue to leave this open?

Piinks avatar Sep 02 '25 20:09 Piinks

Given the many return trips to stale PR triage, the many merge conflicts, and the lack of progress for a year now, I am going to close this PR. Please feel free to reopen if needed @ditman. Thank you!

Piinks avatar Nov 03 '25 22:11 Piinks