PyCharm starts into a previously opened, mostly empty, project in like 5 seconds for me (8700K, NVMe SSD, not sure if RAM clock matters here). My loading time bane for IntelliJ is DataGrip - I make a real mess of open consoles and have like 20 global data sources with rather hefty schemas so that takes a bit to chug through on each startup, loading 10-20-whatever tabs I left before clocking out the day before.
|
|
# ? Mar 24, 2019 18:31 |
|
|
# ? May 15, 2024 13:55 |
|
Does PyCharm still include the features from Webstorm that are good? In other words if I want to dork around with React and Django is it PyCharm or get the full Monty? I tried PyCharm back in 2011 for purely Python and didn’t stick with it but I have a different flow now and I’m interested.
|
# ? Mar 24, 2019 19:29 |
All the web, db, and remote stuff is in pro edition. https://www.jetbrains.com/pycharm/features/editions_comparison_matrix.html
|
|
# ? Mar 24, 2019 20:06 |
|
When does it make more sense to create an object (or serialize a dict) vs creating a new dictionary with remapped fields from a source? I'm working with the Jira REST API and it returns things like customfield_1389235 for any fields created in the Jira admin panel. I only need a subset of the fields, and there is a way to get only a subset of the fields from a Jira Issue resource, but I need to handle a handful of Issue types that have different field requirements (e.g. TicketTypeA needs favorite_color and user_locale, but TicketTypeB needs car_make. Both have a core set of fields like user_id, status, etc). If I made objects there wouldn't be any special methods on them because my application is mostly reading data from the Issue or adding data to fields that come in empty and then calling back to Jira to update the Issue.
|
# ? Mar 24, 2019 20:30 |
I don’t think I understand your question fully, but the task itself looks like the use case data classes primarily exist for.
|
|
# ? Mar 24, 2019 21:22 |
|
Fluue posted:When does it make more sense to create an object (or serialize a dict) vs creating a new dictionary with remapped fields from a source? In your case I'm not sure theres a difference besides how you're calling them? E. Classes might make more sense organizationally though
|
# ? Mar 24, 2019 23:10 |
|
mr_package posted:I'm writing a CRUD app and need to decide on my data storage format. I've started with XML but both native xml and lxml are really bad to work with. I've read the XPATH docs for lxml a hundred times and still cannot search the tree for a specific node. Should I just use JSON instead? YAML? I've used Python's json library before and IIRC converting to a dictionary was really easy, and once you have that working with the data is really easy. If you aren't getting anything out of using XML over something else, just use JSON.
|
# ? Mar 25, 2019 06:12 |
cinci zoo sniper posted:I don’t think I understand your question fully, but the task itself looks like the use case data classes primarily exist for. Yeah I'd probably be breaking attrs out for this
|
|
# ? Mar 25, 2019 11:30 |
|
cinci zoo sniper posted:PyCharm starts into a previously opened, mostly empty, project in like 5 seconds for me (8700K, NVMe SSD, not sure if RAM clock matters here). My loading time bane for IntelliJ is DataGrip - I make a real mess of open consoles and have like 20 global data sources with rather hefty schemas so that takes a bit to chug through on each startup, loading 10-20-whatever tabs I left before clocking out the day before. Hmm, I'll have to do more troubleshooting on this. It used to open just as quick for me, but now it takes 30+ seconds. On the other hand, the good part of having 32GB of RAM is that I basically never close PyCharm or any other program so startup time is rarely an issue. Hed posted:Does PyCharm still include the features from Webstorm that are good? In other words if I want to dork around with React and Django is it PyCharm or get the full Monty? Yes, I've been doing lots of React and Django work in PyCharm Pro for the past couple years. PyCharm is almost a strict superset of WebStorm. The only time WebStorm has something that PyCharm doesn't is when WebStorm gets a new feature release and PyCharm hasn't yet done a new release pulling in those new features.
|
# ? Mar 25, 2019 17:32 |
Yeah same, both computers I use Pycharm on primarily have 16 GB RAM so the only cases when I have to restart it during the work day is if I accidentally hard lock or OOM myself especially well, which hasn’t happened in a year by now. I’d probably check what my plugins are doing if I had your problem - my setup is rather light on those and the only heavy/complicated thing enabled is SonarLint.
|
|
# ? Mar 25, 2019 17:52 |
|
Meyers-Briggs Testicle posted:In your case I'm not sure theres a difference besides how you're calling them? I might be overthinking it then. I do have a sort of "single table inheritance" going on with my classes that deal with the Jira API (which returns everything unless explicitly filtered with query params) because the application is highly dependent upon the ticket types that come in from Jira. I'll need to rethink this, but classes are probably the way to go. Thanks!
|
# ? Mar 26, 2019 05:42 |
Cruious - what do you guys think of PEP 572?
|
|
# ? Mar 26, 2019 19:51 |
|
cinci zoo sniper posted:Cruious - what do you guys think of PEP 572? I just glanced at it but my off the cuff thought is that facilitating code density isn’t admirable in itself. I’ll read over in detail after work.
|
# ? Mar 26, 2019 20:06 |
|
cinci zoo sniper posted:Cruious - what do you guys think of PEP 572? Ehh, I don't think it was necessary and its ugly and I agree with a lot of the detractors points, but I can think of situations where I'd use it over the alternatives. There was/is a lot of vitriol over it, but...get a life people! I've already used it in some demo programs on 3.8.
|
# ? Mar 26, 2019 20:37 |
|
cinci zoo sniper posted:Cruious - what do you guys think of PEP 572? := is off-centered on 99% of typefaces which gives me anxiety
|
# ? Mar 26, 2019 22:00 |
|
There are some situations where it will be very handy, and a whole bunch of examples that make me angry to look at.
|
# ? Mar 27, 2019 02:13 |
|
OnceIWasAnOstrich posted:There are some situations where it will be very handy, and a whole bunch of examples that make me angry to look at. I think they took a few of the more egregious examples out of the pep but early on there was sure some wow really!? stuff in there. It does clean up some situations real nice though.
|
# ? Mar 27, 2019 03:15 |
|
I like that it's called the walrus
|
# ? Mar 27, 2019 06:38 |
|
cinci zoo sniper posted:Cruious - what do you guys think of PEP 572? I feel like it's a terrible idea but I'll surely use it sometimes, it's a feature I abuse a lot in C anyway so... It'll be just like how I use for-else sometimes. It's terrible and dumb but sometimes while typing code I just don't give a poo poo. If the python devs wish to enable my inner perl coder then gently caress the police. edit: https://twitter.com/symbolicbutt/status/1024783816186060800 Symbolic Butt fucked around with this message at 09:43 on Mar 27, 2019 |
# ? Mar 27, 2019 09:40 |
|
Re Tim Peters’ ‘essay’ at the bottom of the PEP, my spicy take is that if he or anyone are hurting for vertical line space in 2019 then they have problems that Python can’t fix.
|
# ? Mar 27, 2019 14:52 |
PyCharm 2019.1 is out. Summary - revamped Jupyter integration; improvements for data classes, debugging, type checking, pytest.
|
|
# ? Mar 27, 2019 15:10 |
|
I have a stupid question. I published a pip package and installed it on my machine (from pip). But when I try to use it, Python can't find it ("No module named 'cyberfloodClient'"). I'm sure I'm doing something really stupid, as I'm very new to Python and don't understand half of what I'm doing. The package is here: https://pypi.org/project/cyberfloodClient/ The source is here: https://github.com/acastaner/cf-py-cfclient/blob/master/cyberfloodClient.py And I try to import by doing code:
code:
code:
|
# ? Mar 27, 2019 19:24 |
|
Did you run the setup.py
|
# ? Mar 27, 2019 19:30 |
|
I had a situation where I installed 3.8 from source and had 3.7 installed with apt, and pip would install packages for 3.7 instead. Try doing code:
|
# ? Mar 27, 2019 21:01 |
|
cinci zoo sniper posted:PyCharm 2019.1 is out. Summary - revamped Jupyter integration; improvements for data classes, debugging, type checking, pytest. The jupyter changes look good. Jupyter notebooks being better in firefox reallydecreased my use of pycharm even though, for .py files, I really liked pycharm. https://www.youtube.com/watch?v=TIZH4aPSN2E
|
# ? Mar 27, 2019 21:01 |
|
Meyers-Briggs Testicle posted:Did you run the setup.py I did dougdrums posted:I had a situation where I installed 3.8 from source and had 3.7 installed with apt, and pip would install packages for 3.7 instead. Try doing I only have Python 3.7 installed
|
# ? Mar 27, 2019 22:19 |
|
I spent a dozen hours working on something that works better than pyautogui for Windows machines. Then while Googlin' something else I found that pywinauto exists and incorporates 90% of what I wanted to do. gently caress.
|
# ? Mar 28, 2019 00:32 |
|
I believe setuptools.find_packages() only works with packages, so it's not actually finding and installing your .py file. Try either converting cyberfloodClient.py to a package (cyberfloodClient/ dir + cyberfloodClient/__init__.py) or using py_modules in your setup.py: code:
|
# ? Mar 28, 2019 02:48 |
|
Don't update to PyCharm 2019.1 if you use a non-US/English keyboard or if you like the way your fonts are currently rendered in 2018.X The new update breaks (seems like) every single keyboard layout that uses AltGr making it impossible to type in characters like # or brackets like {} and/or []. I had this happen to me and also if you look at JetBrains's issues site then it's just full of duplicated entries about this same problem. Also another super annoying thing is that font rendering is completely different now. Using the same font, same settings, the font just looks super thin in the new version and it's doing this weird flickering thing where it goes from thin to not thin (but not as thick as 2018.x) which makes this program not useable. This was reported months ago in the EAP but apparently it's an intended feature. Now that the release version is out though and people are complaining they are "looking into it." I’m really curious how the keyboard issue made it through review. I know most people use a US keyboard layout for programming but apparently JetBrains had absolutely zero people who used something different, despite being an Italian(?) company? E: Czech not Italian. Boris Galerkin fucked around with this message at 13:54 on Mar 28, 2019 |
# ? Mar 28, 2019 13:43 |
|
What the gently caress how could that font nonsense be intended
|
# ? Mar 28, 2019 14:16 |
|
cinci zoo sniper posted:PyCharm 2019.1 is out. Summary - revamped Jupyter integration; improvements for data classes, debugging, type checking, pytest. Are you having any issues viewing DataFrames when working with a notebook? All other variable types open up fine for me except frames and it feels odd and most likely unique to me.
|
# ? Mar 28, 2019 14:31 |
|
the yeti posted:What the gently caress how could that font nonsense be intended I think I was too loose with my words. The new rendering is the feature, the flickering seems to be a bug (maybe? it didn't happen before I updated, and it went away after I downgraded). Not sure if they are related, but for the font rendering a dev said this in January. quote:This is expected behavior of the performance fix (JRE-1008). LCD shaders were used to render a grayscale bitmaps From here. Also it looks like it's only affecting macOS, and the workaround is to either downgrade back to 2018.x or to jump through some extra hoops to use a different version of Java.
|
# ? Mar 28, 2019 14:38 |
|
Boris Galerkin posted:Also it looks like it's only affecting macOS Thank you for your sacrifice. I was going to install this later today. I guess I'll stick with 2018 until they roll out a fix.
|
# ? Mar 28, 2019 14:45 |
vikingstrike posted:Are you having any issues viewing DataFrames when working with a notebook? All other variable types open up fine for me except frames and it feels odd and most likely unique to me. I haven’t tested 2019.1 yet, I’ve been stuck in database audit hell for 3 days straight, going schema to schema, table to table, field to field as this garbage does not have a written documentation. Besides, not a fan of notebooks and haven’t used them in a long rear end while even for one off analytics.
|
|
# ? Mar 28, 2019 15:55 |
|
Aquarium of Lies posted:I believe setuptools.find_packages() only works with packages, so it's not actually finding and installing your .py file. Try either converting cyberfloodClient.py to a package (cyberfloodClient/ dir + cyberfloodClient/__init__.py) or using py_modules in your setup.py: Cool thanks, will try! What, uh, is the difference between a package and a module?
|
# ? Mar 29, 2019 08:01 |
|
A package is a directory with at minimum a __init__.py module. A module is a python file. Edit: Proteus Jones posted:Thank you for your sacrifice. I was going to install this later today. I guess I'll stick with 2018 until they roll out a fix. Thanks for volunteering to give macOS users the a'ok to install it Boris Galerkin fucked around with this message at 08:57 on Mar 29, 2019 |
# ? Mar 29, 2019 08:52 |
|
My project is just a Class that implements the actions of a REST API as functions. Is it it better to make it a package or a module? I'm not sure what the best practices are here :/
|
# ? Mar 29, 2019 10:00 |
|
it's up to you and how you feel like managing your code; you probably don't want 10,000 lines of code in 1 file and you also probably don't want to define a separate file for every 3 line function that you write, so just go with whatever feels right to you. what feels right to me tends to work out to ~1000 line soft cap on single files but that could be higher or lower for someone else and i don't put any effort into enforcing that number, if a file looks too big then I think about whether it makes sense to split some of it up and if I know that I'm working on a project that will probably have a lot of code in it then I plan around that
|
# ? Mar 29, 2019 10:16 |
|
I almost completely ignore line counts for what goes in one file. Think of modules and packages as just higher levels on the code-organization hierarchy that includes functions and classes. In other words, you need to add a module or a package for many of the same reasons you'd use new functions and classes...to help you and others think about your code.
|
# ? Mar 29, 2019 17:34 |
|
|
# ? May 15, 2024 13:55 |
Same, my rule of a thumb for a file is to be able to coherently explain what’s in it using a single sentence.
|
|
# ? Mar 29, 2019 17:51 |