Git Product home page Git Product logo

desktop_cleaner's Introduction

desktop_cleaner's People

Contributors

kallehallden avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

desktop_cleaner's Issues

Import EventHandler could not be resolved

I have spent a few hours working on this and I cannot figure it out.
I followed up with the issue fixes and now I get "Pylance(reportMissingImports)
`from watchdog.observers import Observer

from eventhandler import EventHandler

if name == 'main':
watch_path = Path.home() / 'Desktop'`
I also have the same issue in the EventHandler.py for import extensions.

PermissionError: [WinError 32] The process cannot access the file because it is being used by another process:

This happens when copying a large file. Since watchdog already detected a few bytes coming into the watch_path, the command to transfer that file was triggered, but since the copying process was not yet finished by that time, it returned this error and the program comes to a halt. Weirdly, if I terminate the program and run it again, and copy a small file this time, it works as expected transferring the small file to the destination folder but the large file I transferred earlier is transferred as well.

With this in mind, can you help me fix this by telling the program to wait for the copying process, and then once it is finished, it'll do its thing and transfer the files into the destination folder? Thank you!

You should make the script more general

Stuff like '.mp3' : "/Users/kalle/Desktop/kalle/Media/Audio" should be made using a constant variables containing these common paths. It might be simply a code-defined value, might be a command-line argument. Also, you could use subprocess to find out the path to some directories of the user on different OS's.

According to https://stackoverflow.com/questions/4028904/how-to-get-the-home-directory-in-python, you could do something like:

from pathlib import Path
home = str(Path.home())

ModuleNotFoundError: No module named 'desktop_cleaner'

Traceback (most recent call last):
File "cleandesk.py", line 5, in
import EventHandler
File "/Users/khantanveer/Desktop/desktop_cleaner/EventHandler.py", line 7, in
from desktop_cleaner.extensions import extension_paths
ModuleNotFoundError: No module named 'desktop_cleaner'
Screenshot 2020-05-08 at 11 14 41 PM

ModuleNotFoundError

Traceback (most recent call last):
File "cleandesk.py", line 8, in
from desktop_cleaner.EventHandler import EventHandler
ModuleNotFoundError: No module named 'desktop_cleaner'

Cloned recent project

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.