-
Notifications
You must be signed in to change notification settings - Fork 2
dev #299
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
Merged
Merged
dev #299
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
also avoids a polluted namespace in the console because we do not pass a depth nor object
* fixed resize synchronisation on Qt6 * fixed larray-project#161: use indices for filters (to avoid problems with duplicate labels) * fixed single column plot in viewer when ticks are not strings * fixed bad frac_digits detection in some cases it was caused by set_default_size not working and thus the frac_digit detection using the previous array column widths, which could have been too small * resize axes and vlabel columns automatically * added support for plot with more than 1 dimension in columns (by making plot axes labels customizable by the adapter) * allow registering an adapter via an explicit function call instead of via a decorator * adapters can be registered using a string (so that we do not load the module just to register the adapter) looked-up adapters are cached for faster retrieval for subsequent instances of that type * adapters are used to display instances of their subclasses. When there is both an adapter for a parent class and a subclass, we use the adapter for the subclass by sorting registered types by the length of their mro. Note that string types always come last (so we cannot have two string types inheriting from each other) * added support for per-column color value * WIP: adapters can return simple sequences instead of ndarrays (buggy for list of sequences) * split get_adapter in two steps: get_adapter_creator which gets a callable and calling that callable to actually get an adapter * made writing adapters easier and to avoid having to load all data in memory * WIP (needs more code documentation): generalized bg_value to an attributes dict each value in the dict *must* have the same type than "data" (or at least quack like it) * moved features from specific models to AbstractArrayModel now all models can have decorations, bg_value, etc. allowed adapters to return just "values" (no dict) (unsure it's a good idea though) * WIP (need to allow "unsorting" + implement sort for more adapters): adapters can implement sort axis/column * added alignment handling in model * removed custom format_func because that should not pass the adapter/model boundary which will probably one day be a server/client boundary too * do not consider tuples as sequences in arraymodel anymore. This makes some stuff less convenient in a few adapters (Pandas, etc.) but fixes displaying mixed_tuples. Maybe that's not the correct way to fix this though. * implemented adapters for many builtin container types: - sequences (list, tuple, ...) - mappings (dict, OrderedDict, ...) - collections (set, ...), - namedtuple (we cannot dispatch to this adapter just by looking at the type of data because the generated namedtuple classes inherit directly from tuple, not namedtuple) - array.array objects * implemented native adapters for numpy arrays (homogeneous and structured) instead of converting them to LArray * implemented adapters for pandas.DataFrame and pandas.Series * added adapters for pyarrow.Array and pyarrow.Table * added adapter for pyarrow.ParquetFile * implemented adapter for polars.DataFrame and polars.LazyFrame * WIP (need test): implemented adapter for profiler stats (pstats.Stats) * WIP (need test): implemented adapter for pytables.Table, pytables.Array and pytables.Group representing Pandas DataFrame * WIP (need test): added adapter for binary files * implemented adapter for text files * implemented adapter for larray.inout.xw_excel.Workbook, Sheet and Range * added (commented) adapter for object type (ie ultimate fallback adapter) The problem is that this shows too many objects in the left column. We need to sort that list by type and add type filter buttons before we uncomment this * implemented adapter for Path objects - generic adapter with a way to register new adapters for other extensions - adapters for .py, .yml, .txt files - adapter for directories - adapter for .csv files - WIP (needs test): adapter for .sas7bdat files - adapter for .feather/.arrow/.ipc files - adapter for .parquet files * added adapters for zipfile.ZipFile and zipfile.Path * added adapter for memory view * implemented sqlite3 connection adapter * adapter for narwhals data/lazyframe * WIP (needs test): adapter for Ibis Table * nicer digits detection code * nicer code for computing colors * renamed set_format method to set_frac_digits_or_scientific for clarity * removed unused frac_digits attribute * better assertion messages * changed show_figure arguments order to make it more logical * more robust axis drag and drop and move it to its own class Many edge cases were fixed: - drag and drop from another app should not be accepted - different cases of interrupted drag and drop followed by another drag had strange consequences - dragging the "Filters" label should have no effect at all
… all the cells with differences are 0 in the first array (fixes larray-project#288)
so that it does not fluctuate so much on scroll also resets row heights to "automatic" when autosizing
on failure sniff encoding again and decode using errors='replace'
…pe we do not support
… mixed type Polars DF
* sort implemented on DirectoryPath, Polars DF and LF and Narwhals LF, Sqlite Table and DuckDBRelation * filters implemented on Pandas DF, Polars DF and LF * reset sort when changing the filter. There are cases where we could keep it but this will have to wait later
sometimes the exception message itself contains unprintable data (e.g. unicode string with characters which cannot be encoded to the stderr encoding)
…able modules give priority to polars because it has more features
…nstalled also optimized chunk decoding
Otherwise, the ipython console raise exceptions. This bug is masked when xlwings is present because it imports matplotlib.figure itself
(and dropped support for 3.8)
the editor should now work out of the box when installed via pip install
It is *much* faster than pyreadstat to read the first rows. However, it does not support offset, so reading the end of large files will be awfully slow. Even though this is obviously not a perfect solution, I think this is an improvement because the first rows are often the most interesting ones.
as recommended by conda-forge-linter
This was referenced Dec 15, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
It's finally time for the BIG merge