|
huhu posted:I started developing with Sublime Text and then switched to PyCharm since I've been working mostly with Python. However, my new job has me focusing on Flask apps and PyCharm seems to be a bit lacking when it comes to dealing with HTML, CSS, and JS. I miss all the awesome plugins that come with Sublime Text as well. Am I missing something or should I be looking at something else to be developing Flask stuff? I feel like I might be saying this too often at this point, but have you considered VSCode accepted Christ as your Lord and Savior https://code.visualstudio.com/docs/languages/python
|
# ¿ Apr 12, 2017 21:13 |
|
|
# ¿ Apr 29, 2024 03:25 |
|
This was my favorite line from that:quote:Vigil deleted a function. Won't that cause the functions that call it to fail?
|
# ¿ Sep 22, 2017 19:55 |
|
Yes and there are a lot of them. Some of them are actually good.
|
# ¿ Oct 31, 2017 18:57 |
|
Also try postman: https://www.getpostman.com/
|
# ¿ Dec 5, 2017 17:14 |
|
I don’t use pycharm, but I would start here: https://www.jetbrains.com/help/pycharm/debugging.html
|
# ¿ Mar 19, 2018 03:22 |
|
Yeah, Basic Auth doesn't work for Sharepoint. You can do user auth if you're using the Sharepoint CSOM: https://docs.microsoft.com/en-us/sharepoint/dev/sp-add-ins/complete-basic-operations-using-sharepoint-client-library-code The "correct" way is to use an app registration and authentication token through the graph api: https://docs.microsoft.com/en-us/onedrive/developer/rest-api/ https://docs.microsoft.com/en-us/onedrive/developer/rest-api/getting-started/app-registration edit: just realized this was a the python thread, here's something python specific that my help: https://github.com/vgrem/Office365-REST-Python-Client The Fool fucked around with this message at 18:23 on May 14, 2018 |
# ¿ May 14, 2018 18:18 |
|
jonwayne is a pro though
|
# ¿ May 15, 2018 01:20 |
|
I love me some elk. Oh wait, wrong forum. ELK is good too, if you want a super low effort self hosted ELK style setup and have any docker experience, it is super easy to get Graylog setup in containers.
|
# ¿ Jun 1, 2018 06:22 |
|
Can someone explain the __future__ library to my like I'm an idiot. I've done some googling, but I'm still not sure I get the point.
|
# ¿ Jun 25, 2018 22:56 |
|
Like if I wanted a 3 feature in 2.7?
|
# ¿ Jun 25, 2018 23:48 |
|
At work in am receiving a backup of an Sql database, but I will not be getting control of any of the existing infrastructure or front end. I was thinking about throwing up a quick and dirty Django front end, but have no idea how to set up the orm to handle an existing database. Is there an accepted best practice? Should I just build out a new table structure that I can import the data into, or is there a better way?
|
# ¿ Jul 4, 2018 04:17 |
|
Forget about Python specifically for a little bit and try sketching the problem out on paper first. In plain language, write out the logic needed to solve the problem step by step, be as granular as possible. Then you can start replacing your logical steps with actual Python code.
|
# ¿ Jul 23, 2018 18:18 |
|
DRF supports token authentication. https://www.django-rest-framework.org/api-guide/authentication/#tokenauthentication
|
# ¿ Jan 28, 2019 18:48 |
|
I understand PHP has a pretty bad package management situation too.
|
# ¿ Feb 5, 2019 18:12 |
|
Thermopyle posted:I'm wanting to create a server process that other processes can subscribe to to get a stream of events from. Note that these are processes all on one machine. Friend of mine did a similar thing using twisted, might be worth looking at.
|
# ¿ Apr 5, 2019 18:58 |
|
The benefit is to be able to develop in an environment as close to production as possible. With Docker you can deploy the same configurations as production without a bunch of admin overhead. You also wouldn't develop "inside a container", you'd either push your code through vc and a hook would bring it in to docker, or your dev docker configuration would have a volume pointing at your code on your workstation.
|
# ¿ Apr 8, 2019 17:43 |
|
Hadlock posted:I may write up an OP for one here later this week. Watching developers gently caress around with "dockers" is like a sweaty nerd trying to figure out how to finger bang an unlucky girl in the back of a car for the first time I think a docker/container specific thread would be a good idea. The topic has come up quite a bit in the last week across multiple IT and dev threads.
|
# ¿ Apr 10, 2019 17:09 |
|
I absolutely prefer reading to videos. Don't do dead trees anymore though, all online. Usually whatever random blog I ended up at after a half-assed Google search. If find the inaccuracies of the blog forcing me to think harder is better for my learning process.
|
# ¿ May 3, 2019 03:56 |
|
StashAugustine posted:Hey I'm doing some work with python on Ubuntu. What's a good text editor for that? Gedit is kinda lovely about indentation sometimes (or maybe I'm just dumb) https://code.visualstudio.com/docs/setup/linux
|
# ¿ May 24, 2019 20:50 |
|
Mycroft Holmes posted:i'm doing some homework and could use some help. strings are arrays of characters
|
# ¿ Jun 25, 2019 19:23 |
|
Mycroft Holmes posted:I am aware of that. I need a section of code that works regardless of how many strings are in the array Then maybe I didn't understand which part you needed help with. In broad strokes: You use your for loop to loop through your array of strings. For each string in your array, you display the first character of the string. Mycroft Holmes posted:i also have another array that is a list of vowels. I need to count how many times the vowels in array 2 appear in the array 1. How can I do this? there are better ways to do this, but the naive way would be to use two loops: use a for loop each vowel, then loop through your string comparing the current letter to current vowel if you get a match, increment a counter
|
# ¿ Jun 25, 2019 19:36 |
|
Mycroft Holmes posted:ok, so i've got Python code:
Then x will be a number that automatically increments for the length of a. Then you can access the first element of your second dimension by a[x][0] The Fool fucked around with this message at 20:11 on Jun 25, 2019 |
# ¿ Jun 25, 2019 20:09 |
|
Mycroft Holmes posted:cool, that works. Now, the strings are of variable length. how do i print only the last letter of the string? is there a function for that? Someone else answered that already further up.
|
# ¿ Jun 25, 2019 20:15 |
|
Assuming a is a list of words Make a counter that starts at 0 Loop through a for each word Check the letter count of each word Increment your counter by the number of letters When the loop is over, print the final count
|
# ¿ Jun 25, 2019 20:24 |
|
Wallet posted:The list of vowels posted has both capital and lowercase (for whatever reason) so I assume that's not the issue. I believe he was counting just 'E' or just 'e', and I assume he needed the count of both.
|
# ¿ Jun 25, 2019 23:28 |
|
I'm merging a couple csv's with pandas and am having issues with numbers getting rounded up when using pandas.read_csv. For example: 1904.9999 becomes 1905 Any suggestions? I spent a couple hours on google trying to figure this out and nothing I've tried has worked.
|
# ¿ Jul 18, 2019 20:55 |
|
float_precision on it's own wasn't working, but adding the other two arguments did. Thanks.
|
# ¿ Jul 18, 2019 21:50 |
|
Krakkles posted:Dumb question I can’t figure out: how do you get PyCharm on windows to see packages installed to python on ubuntu/WSL? You don't, you'll have to install those packages in windows as well. There is a way to symlink stuff between WSL and windows, but it'll be a huge pain in the rear end and probably not work right.
|
# ¿ Aug 13, 2019 22:42 |
|
You can't have hyperv installed at all if you want to run virtual box. Also, docker toolbox is legacy and not recommended.
|
# ¿ Aug 14, 2019 20:28 |
|
ImageMagick?
|
# ¿ Aug 14, 2019 21:40 |
|
C++ does a better job of keeping you from getting lost at sea.
|
# ¿ Aug 19, 2019 17:00 |
|
Meyers-Briggs Testicle posted:try something like this I’ve used the obs virtual cam at work with Skype/teams and zoom with no issues. Was fun to do fancy transitions between sharing my desktop and my webcam or to throw up a white screen with the company logo.
|
# ¿ Dec 19, 2019 22:21 |
|
Pandas question: I have a dataframe that I am doing groupby().agg() on to merge duplicate ID's and sum specific columns. It has a bunch of columns, but I only need to sum 3 of them. This all works. My question is, how can I do this without having to specify every single column in the dataframe?
|
# ¿ Jan 29, 2020 21:31 |
|
CarForumPoster posted:Could you provide an input, expected output and example bit of code and what the output? I'm not sure why you'd specify all column names to accomplish that. Given a table with the following columns that matter, and a bunch of columns that I don't need to process at all: pre:id | a | b | total ----|---|---|-------- 1 | 0 | 3 | 3 2 | 1 | 0 | 1 2 | 0 | 3 | 3 3 | 2 | 0 | 2 4 | 0 | 2 | 2 end result looking like this: pre:id | a | b | total ----|---|---|-------- 1 | 0 | 3 | 3 2 | 1 | 3 | 4 3 | 2 | 0 | 2 4 | 0 | 2 | 2 code:
My issue is that if I don't explicitly list every single column, they are not present in the resulting dataframe.
|
# ¿ Jan 29, 2020 22:07 |
|
That'll work a treat, thanks. Didn't occur to me to built the dict like that, I was assuming pandas would have some flag somewhere that would do it automatically.
|
# ¿ Jan 29, 2020 22:28 |
|
Last two projects I’ve been able to get away with using pandas as a orm and it’s been great. Going to be super annoyed the next time I need to do something more complicated.
|
# ¿ Apr 8, 2020 22:31 |
|
Flask probably e: a link - https://dev.to/nagatodev/getting-started-with-flask-1kn1
|
# ¿ Feb 16, 2023 18:34 |
|
I did freecodecamp when it was just javascript and it was well designed, they have a bunch of other stuff now including some python courses: https://www.freecodecamp.org/learn
|
# ¿ Mar 6, 2023 17:00 |
|
If what you're working with is loaded into a dict would something like deepdiff work?
|
# ¿ Mar 9, 2023 16:41 |
|
|
# ¿ Apr 29, 2024 03:25 |
|
dehumanize yourself and write a terraform provider
|
# ¿ Mar 10, 2023 22:42 |