Comments (24)
I just recently reinstalled Windows and it seems to me that this program worked for me before
this explains everything
from ivpt.
By the way, on Ubuntu this program works🤔
from ivpt.
@IvanIsak2000 pattern matching was added to python in 3.10. my python version is written in runtime.txt
it can be easilly substituted with if/else statements; you can make a PR for this us you're interested
from ivpt.
@IvanIsak2000 it seems you have a newer python version on your ubuntu system
from ivpt.
I have not yet tested the program on Linux
my apologies;
but you made these screenshots in README.md, and seems it was working fine
from ivpt.
@IvanIsak2000 i use arch btw
from ivpt.
Weird, I installed Python 3.10.6 and another problem appeared
can you try this on a linux system? i'm currently a bit busy with other stuff, and windows machine is far away - i cannot rest it myself rn
from ivpt.
@IvanIsak2000 works perfectly for me:
$ python --version
Python 3.11.1
can you provide more information about the error, please?
from ivpt.
I will test again.
At the moment (3.10.6 python) it looks like this:
from ivpt.
On Python 3.11.3:
from ivpt.
maybe doesn't work because Windows can't handle double backslashes
from ivpt.
well, that's weird. I have checked everything, there's no double forward slash
@IvanIsak2000 can you show me the output of
import os
print(os.sep)
on that windows system?
from ivpt.
well, that's weird. I have checked everything, there's no double forward slash
@IvanIsak2000 can you show me the output ofimport os print(os.sep)on that windows system?
I did
Result :
\
from ivpt.
@IvanIsak2000 i really do not know what to do. the only thing left - delete ~/.IVPT
folder and try one more time.
Thank you for all your tests, but unfortunately, i cannot reproduce this thing. You may try to fix it yourself, it has something to deal with src/essential/config.py
. That file is needed to read and create-if-not-exist (aka linux touch
command) configuration file in ~/.IVPT/config.toml
from ivpt.
i doubt stdlib modules can misbehave. Anyway, if you want to statically set your paths, you need to correct config.py
(see comments below):
...
def configuration() -> dict:
# build user config path with default path separator os.path
config_path = os.sep.join([os.path.expanduser("~"), ".IVPT", "config.toml"])
config = None
# build default config path with default path separator os.path
default_config = os.sep.join(["src", "essential", "default_config.toml"])
path_items_list = list(config_path.split(os.sep))[1:]
# make all the directories needed for files creation (here, os.path is used once again)
for index in range(len(path_items_list)):
cur_dir = os.sep + os.sep.join(path_items_list[0: index])
if not os.path.isdir(cur_dir):
os.mkdir(cur_dir)
# create file if not exists, and fill with default contents
if not os.path.isfile(config_path):
with open(default_config, "r", encoding="utf-8") as output_file:
contents = output_file.read()
with open(config_path, "w", encoding="utf-8") as input_file:
input_file.write(contents)
# load configuration
try:
with open(config_path, "rb") as file:
toml_dict = load(file)
config = toml_dict
except ... # handle exceptions
so there're 2 files:
src/essential/default_config.toml
and
~/.IVPT/config.toml
from ivpt.
i'll try it myself, too - as soon as i find windows pc
from ivpt.
I have not yet tested the program on Linux
from ivpt.
I just recently reinstalled Windows and it seems to me that this program worked for me before
from ivpt.
Weird, I installed Python 3.10.6 and another problem appeared
from ivpt.
It is strange that it does not work on Ubuntu either, although nothing was reinstalled from the installation
from ivpt.
@IvanIsak2000 i really do not know what to do. the only thing left - delete
~/.IVPT
folder and try one more time.
Thank you for all your tests, but unfortunately, i cannot reproduce this thing. You may try to fix it yourself, it has something to deal withsrc/essential/config.py
. That file is needed to read and create-if-not-exist (aka linuxtouch
command) configuration file in~/.IVPT/config.toml
Can you write a tree of all folders/files so that I can skip defining the paths and populate them myself?
from ivpt.
@IvanIsak2000 i really do not know what to do. the only thing left - delete
~/.IVPT
folder and try one more time.
Thank you for all your tests, but unfortunately, i cannot reproduce this thing. You may try to fix it yourself, it has something to deal withsrc/essential/config.py
. That file is needed to read and create-if-not-exist (aka linuxtouch
command) configuration file in~/.IVPT/config.toml
Can you write a tree of all folders/files so that I can skip defining the paths and populate them myself?
sorry, what do you mean?
from ivpt.
@IvanIsak2000 i really do not know what to do. the only thing left - delete
~/.IVPT
folder and try one more time.
Thank you for all your tests, but unfortunately, i cannot reproduce this thing. You may try to fix it yourself, it has something to deal withsrc/essential/config.py
. That file is needed to read and create-if-not-exist (aka linuxtouch
command) configuration file in~/.IVPT/config.toml
Can you write a tree of all folders/files so that I can skip defining the paths and populate them myself?
sorry, what do you mean?
I saw that the paths for files are calculated using libraries, but since they do not work correctly, I can specify the path myself
from ivpt.
@IvanIsak2000 so, a year have passed. i tried on windows, everything works smoothly. does it still fails for you?
from ivpt.
Related Issues (20)
- add language point to config HOT 1
- write README.md HOT 1
- update wiki description page
- key checks when loading config file
- fonts look differently on different os
- interface: draw columns and rows
- feat: window for stoichiometry sums
- create database methods to shift old items when a new one is added
- add CHANGELOG.md HOT 1
- Add element group colors HOT 2
- pack into executable file HOT 1
- create UPDATE database methods
- move to AGPL v3 license
- some code to be executed when file is launched as main script
- database unittests HOT 1
- create file folding HOT 1
- create interface HOT 1
- compile with pyinstaller HOT 1
- unittests for classes communicating with periodictable HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ivpt.