-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Currently, I identify several points for improving the class logic and making the package more "pythonic".
- Folder naming conventions/classes and file naming conventions/classes are completely decoupled. A framework uniting both classes would make sense.
- Add magic methods like
__str__
or__add__
(e.g. adding a path to a tree) and properties liken_paths
,n_files
, ordisk_usage
to better interact with an object. Especially, replace functions doing printing, e.g.print_file_register
and replace them with sth. like this https://pypi.org/project/seedir/ - I would prefer to have stacked function calls, which always return
self
, e.g.tree.filter(level, pattern='..').filter(level, pattern='..').prune(level)
and not having all these "collect" functions. - Temporary creation of data frames should be prevented. It would be better to have a central data frame dealing with folders and files (see
get_disk_usage
orsearch_files_ts
) - Building a tree is quite slow at the moment, because it uses
os.walk
and does not utilise parallelisation. - Refactor
build_smarttree
in general - a lot of list appends happen there, even after one knows the "dimensions" of paths and folders. - Regex patterns should be used as a general entry point for filtering folders or file names, not starting from a tuple of strings.
- Its currently quite difficult to understand how to use geopathfinder in detail. More docs and Jupyter Notebooks should be added.
This should just be the central issue collecting and discussing improvements or new ideas, which then can be distributed to other issues later on. Please feel free to add your ideas and thoughts - this should be considered as a brainstorming. If we come up with a specific set of tasks, we could also ask a student or a new employee to implement them.
And by the way: I did not find a package, which does already similar things - so this might be a huge benefit for the community!
Metadata
Metadata
Labels
enhancementNew feature or requestNew feature or request