gsohler / openscad

OpenSCAD - The Programmers Solid 3D CAD Modeller
https://www.openscad.org
Other
14 stars 6 forks source link

Adds python style comments to editor #6

Closed Matthieu-LAURENT39 closed 11 months ago

Matthieu-LAURENT39 commented 11 months ago

This adds "#" comments when python mode is enabled (resolves #5 ) And most importantly, it allows the editor to know when python mode is on (resolves #4 )

Matthieu-LAURENT39 commented 11 months ago

Not too sure why all the builds are failing, the changes i made where either unrelated to python or in a #ifdef block Maybe it's because i added a new include? i'll try forward declaration instead

gsohler commented 11 months ago

Hi Matthieu, dont worry about these at the moment. I believe something else broke in the meantime. I see same issue with my PR's This needs to be addressed separately.

On Sun, Jul 30, 2023 at 5:27 PM Matthieu LAURENT @.***> wrote:

Not too sure why all the builds are failing, the changes i made where either unrelated to python or in a #ifdef block

— Reply to this email directly, view it on GitHub https://github.com/gsohler/openscad/pull/6#issuecomment-1657201147, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCO4MXRIJRAR4M4BH5K6ADXSZ4PPANCNFSM6AAAAAA25H7T7I . You are receiving this because you are subscribed to this thread.Message ID: @.***>

Matthieu-LAURENT39 commented 11 months ago

Ah, i see Well if this isn't a problem then this PR is finalised, should be good to merge if you don't see any other issues

gsohler commented 11 months ago

mathieu, its known issue that all ctests fail for my python branch, because i don't take care on ctests for the python branch, I dont plan to get my python branch merged to main openscad branch at the moment.

gsohler commented 11 months ago

if you like to see your changes in the main openscad mid term, focus on python-pr3 if you rather want to work at the bleeding edge of python-openscad without ctests in sync, focus on python branch instead.

Matthieu-LAURENT39 commented 11 months ago

I see, i might add this to python-pr3 then, since it improves usability for the end-user by quite a lot, and doesn't break anything Should i open another PR?

gsohler commented 11 months ago

no need. i just merged your changes from python to python-pr3 mentioning your name in the meantime, also macos build compiles again. all your work is now included in our python-pr3 for pr (with double manstrength) now its teepee's task to check and maybe approve (and this PR is in the pole position as its the only pr which can solve the macos compilation errors)

Thank you for your valuable contribution, i am excited!

gsohler commented 11 months ago

About the +=, -= *= operators:

I believe its quite easy to implement them, and these are apparently missing see

https://docs.python.org/3/c-api/typeobj.html#c.PyNumberMethods

Are interested into taking the challenge or shall i focus on it ?

BTW: is there an option to chat with you ? whats your favorite chat platform ?

Matthieu-LAURENT39 commented 11 months ago

i just merged your changes from python to python-pr3 mentioning your name

There's actually a specific synthax in git commit messages for when you copy code from someone else, you can add Co-authored-by: name <email@example.com> at the end of your commit message so the commit is attributed to the correct person in the history tree. I don't really mind, but just saying for future use

I believe its quite easy to implement them, and these are apparently missing

Are you sure they're missing? I used them a bit and they seem to work fine But if they don't work, i'm don't mind working on them

BTW: is there an option to chat with you ? whats your favorite chat platform ?

I use matrix and discord, and if there's a need i can dust up my old XMPP server

gsohler commented 11 months ago

Haha, i just tested and it works! I did not implement them, so i did not expect them to work. but this python is clever :)

On Sun, Jul 30, 2023 at 10:51 PM Matthieu LAURENT @.***> wrote:

i just merged your changes from python to python-pr3 mentioning your name There's actually a specific synthax in git commit messages for when you copy code from someone else, you can add Co-authored-by: name < @.***> at the end of your commit message so the commit is attributed to the correct person in the history tree. I don't really mind, but just saying for future use

I believe its quite easy to implement them, and these are apparently missing Are you sure they're missing? I used them a bit and they seem to work fine But if they don't work, i'm don't mind working on them

BTW: is there an option to chat with you ? whats your favorite chat platform ? I use matrix and discord, and if there's a need i can dust up my old XMPP server

— Reply to this email directly, view it on GitHub https://github.com/gsohler/openscad/pull/6#issuecomment-1657264132, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCO4MSUMHG5GGE2WKCEFOLXS3CMFANCNFSM6AAAAAA25H7T7I . You are receiving this because you modified the open/close state.Message ID: @.***>

Matthieu-LAURENT39 commented 11 months ago

Indeed, it's nice how you can implement the bare minimum and it extrapolates the rest!