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
Compare folder A and subfolder B and show files that are in folder A but not in subfolder B #113736
Comments
|
Here is the structure fo folder, subfolder and files: |
|
Right now this does not look like a bug in CPython, but looks like a bug in your code :) Please, simplify the reproducer, show what do you expect to happen, what happens and try the latest version of python (if you are confident that this is really a bug in CPython itself). |
|
And when simplifying the reproducer, make sure that we can run the code, without any additional setup. Your reproducer should create whatever minimum directories and files are needed to show the problem. |
|
it is possible that this code works on other computers. I had some older versions of Python, but I uninstalled the old one and installed the new version Python 3.12.1 However, there is something strange. All tested code versions, also made with ChatGPT, have a problem with FODLER vs SUBFOLDER comparison. That is, instead of finding only the html files in FOLDER A, the code also finds the html files in SUBFOLDER B. If the error is from me, what should I do to make it work? Another version: OR THIS ONE |
|
WORKS. The problem was with the version of Python. Thank you! VERSION 2. This version compares files by both name and content. We check that the content of each shared file is different and show the files that exist in only one of the folders. |
|
In the future, please seek help at https://discuss.python.org/c/users/7 before opening an issue here. |
Bug report
Bug description:
I think Python itself has a BIG BUG. It's a folder and subfolder problem. If they were just different folders, it would have worked fine. But there is something wrong with the combination of find files from FOLDER vs SUBFOLDER.
It is a conflict between folder and subfolder. Compare folder A and subfolder B and show files that are in folder A but not in subfolder B. And when checking, it sees the different files from both folders, but when displaying it, it can't show me only the files that are in folder A, and which are not found in subfolder B
please see this topic:
https://stackoverflow.com/questions/77764496/compare-folder-a-and-subfolder-b-and-show-files-that-are-in-folder-a-but-not-in
I try many combinations,
Another version of the code here:
CPython versions tested on:
3.8
Operating systems tested on:
Windows
The text was updated successfully, but these errors were encountered: