Re: new here

2024-08-22 Thread rbowman via Python-list
On Wed, 21 Aug 2024 22:04:14 +0100, Daniel wrote:

> I am on forums but tend to stay away from them unless I absolutely have
> to. I like newsgroups as they are - though I have noticed a massive drop
> in users ever since Google dropped their groups service. I also saw a
> minor drop in spam.

Absolutely. It was sort of an intelligence test. I've used the server at 
the Freie Universität Berlin from back in the days when it was free rather 
than 10 Euros a year so life went on smoothly.
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread rbowman via Python-list
On Wed, 21 Aug 2024 22:15:37 +0100, Daniel wrote:

> Lesser used protocols not known by many in the mainstream. Such as:
> 
> gopher, gemini, finger, spartan, titan, etc.
> 
> An example of use, here's a weather service tied to a finger. Put your
> city name as the user. This isn't mine, but it is inspiring. Example:
> 
> finger mi...@graph.no
> 
> For all options, go to the help finger:
> 
> finger h...@graph.no

Thanks. Interesting. I was surprised a Norwegian site would have data for 
a small city in the US. I have a Python script that accesses the NOAA 
(National Oceanic and Atmospheric Administration) API and the data in the 
Meteogram appears to match well. fwiw, all that does is

   observation_url = f"https://api.weather.gov/stations/K{grid_id}/
observations/latest"
response = requests.get(observation_url).json()

using the Python 'requests' package and then parsing out the JSON.  
Implementing finger probably would be a straight socket connection. I 
don't know how useful this is: 

https://pypi.org/project/pyfinger/

I assume gopher is fron the archie, veronica, and jughead days. It appears 
straightforward.

https://datatracker.ietf.org/doc/html/rfc1436

It's another use of a simple socket connection.

https://docs.python.org/3/howto/sockets.html

You may be able to gleam something from

https://sr.ht/~lioploum/offpunk/



-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread rbowman via Python-list
On Thu, 22 Aug 2024 13:43:59 +1200, dn wrote:

> The OpSys on this machine no longer features finger (available for
> installation as an 'extra').

My Ubuntu 22.04 box has it, the Fedora 40 one doesn't. Ubuntu offers to 
install gopher, Fedora doesn't. Go figure. 
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread Daniel via Python-list
rbowman  writes:

> On Wed, 21 Aug 2024 22:15:37 +0100, Daniel wrote:
>
>> Lesser used protocols not known by many in the mainstream. Such as:
>> 
>> gopher, gemini, finger, spartan, titan, etc.
>> 
>> An example of use, here's a weather service tied to a finger. Put your
>> city name as the user. This isn't mine, but it is inspiring. Example:
>> 
>> finger mi...@graph.no
>> 
>> For all options, go to the help finger:
>> 
>> finger h...@graph.no
>
> Thanks. Interesting. I was surprised a Norwegian site would have data for 
> a small city in the US. I have a Python script that accesses the NOAA 
> (National Oceanic and Atmospheric Administration) API and the data in the 
> Meteogram appears to match well. fwiw, all that does is
>
>observation_url = f"https://api.weather.gov/stations/K{grid_id}/
> observations/latest"
> response = requests.get(observation_url).json()

I think he uses a weather service API to call the data, and I'm sure
they all share data across other national weather services. That's just
a guess. 

>
> using the Python 'requests' package and then parsing out the JSON.  
> Implementing finger probably would be a straight socket connection. I 
> don't know how useful this is: 
>
> https://pypi.org/project/pyfinger/
>
> I assume gopher is fron the archie, veronica, and jughead days. It appears 
> straightforward.

I use gopher all the time, and the lynx browser supports it directly.

If you have lynx, you can visit this gopher interface to Wikipedia:

gopher://gopherpedia.com

If you like Reddit, there's this

gopher://gopherddit.com

Of course it's read only, but if you're wishing to leisurely read posts
on reddit in a super fast gopher page, you can.

Right now, I'm focused on providing wiktionary.org services on gopher as
well as finger.

These are longterm projects since I can only learn python and code on
spare time, which I have little.

/snip

I will be posting my coding questions in here.

Thanks guys.

Daniel
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread Daniel via Python-list
Jason Friedman  writes:

> On Wed, Aug 21, 2024 at 4:04 PM Daniel via Python-list <
> python-list@python.org> wrote:
>
>>
>> An example of use, here's a weather service tied to a finger. Put your
>> city name as the user. This isn't mine, but it is inspiring. Example:
>>
>> finger mi...@graph.no
>>
>> For all options, go to the help finger:
>>
>> finger h...@graph.no
>
>
> Quite cool!

Right? It's so quick too. Just thinking how broad you can make it -
accessing live data on the internet without the need of a broadband
connection.

If you want to check out the fingerverse

finger fingerve...@happynetbox.com

If you remember webrings, there's a finger ring, though there aren't
alot of fingers registered on there yet. 

finger r...@thebackupbox.net

Daniel
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread rbowman via Python-list
On Thu, 22 Aug 2024 10:40:52 -0700, Paul Rubin wrote:

> The Pico uses MicroPython which is stuck on an old version of Python,
> unfortunately.

I think it's up to 3.4 in general and erratic past that. It doesn't have 
the match from 3.10.  I don't think it has f-strings though it may have 
the walrus. There are workarounds but it can be annoying. 

I haven't worked with CircuitPython lately and don't know if it has pulled 
in later features. 

-- 
https://mail.python.org/mailman/listinfo/python-list


RE: new here

2024-08-22 Thread AVI GROSS via Python-list
After looking at what is going on in the other area, I am convinced that we
need multiple boards with different ideas of what should be moderated or
even ones where only very egregious behavior gets you banned. There is
serious debate there about whether the group of people in charge of a more
focused set of duties should even be given the ability to manage the mailing
lists versus others.

There are advantages to having a safe environment but not when the keepers
want to stifle dissent or promote their own agendas as if everyone buys into
them.

I see hints there will be changes there as they were a tad tone deaf and did
not seem to care if anyone objected.

Let's keep this forum going.

-Original Message-
From: Python-list  On
Behalf Of Dan Sommers via Python-list
Sent: Wednesday, August 21, 2024 4:57 AM
To: python-list@python.org
Subject: Re: new here

On 2024-08-20 at 23:16:48 -0400,
AVI GROSS via Python-list  wrote:

> I do wonder if the people at python.org want multiple forums. There is
> also one that sort of tutors people that obviously has an overlapping
> but different audience.

$ python -m this
The Zen of Python, by Tim Peters
[...]
There should be one-- and preferably only one --obvious way to do it.
Although that way may not be obvious at first unless you're Dutch.
[...]
-- 
https://mail.python.org/mailman/listinfo/python-list

-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread rbowman via Python-list
On Thu, 22 Aug 2024 09:10:00 +0100, Daniel wrote:

> If you have lynx, you can visit this gopher interface to Wikipedia:
> 
> gopher://gopherpedia.com

Yeah, that works and I could find Hillbilly Elegy (film). The text was 
fine but the 'Accolades' table was garbled. It came up on the Netflix 
recommendations and I watched it last night so when it said 'Search' I 
wanted to see what it would do. It came back with links to the book, the 
film, the Vances, and cast member bios.  It's a subset of the Wiki 'Search 
in..' but still impressive. 

Python certainly will get the job done either on the client or server 
side. Being retro tech should make life easier than some of the web 
services frameworks. 

-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread dn via Python-list

On 23/08/24 07:49, rbowman via Python-list wrote:

On Thu, 22 Aug 2024 10:40:52 -0700, Paul Rubin wrote:


The Pico uses MicroPython which is stuck on an old version of Python,
unfortunately.


How did this enter the conversation/thread?

Paul's 'contribution' does not even appear on the Archive...



I think it's up to 3.4 in general and erratic past that. It doesn't have
the match from 3.10.  I don't think it has f-strings though it may have
the walrus. There are workarounds but it can be annoying.


Two points:

- it's cut-down to work on bare-metal which makes for low demands on 
resources, but commensurate shortage of the facilities we CPython 
developers take for-granted (ie may allow ourselves to find annoying)


- it has f-strings, but frustrates those of us who prefer F-strings

- the docs point-out that (compared with full-fat Python) it is less 
consistent across environments. Accordingly, worth reading the "Quick 
Reference for [your processor]" sections of the docs, eg R-Pi Pico 
version only has half of the ADC-methods.



Once scale expectations to take into account the power of the processor, 
MicroPython goes-like-the-clappers!




I haven't worked with CircuitPython lately and don't know if it has pulled
in later features.


Have you (gentle reader) used both and feel able to offer a comparison - 
when to prefer one over the other?




[https://www.phrases.org.uk/meanings/like-the-clappers.html]
--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread rbowman via Python-list
On Fri, 23 Aug 2024 08:36:02 +1200, dn wrote:

> On 23/08/24 07:49, rbowman via Python-list wrote:
>> On Thu, 22 Aug 2024 10:40:52 -0700, Paul Rubin wrote:
>> 
>>> The Pico uses MicroPython which is stuck on an old version of Python,
>>> unfortunately.
> 
> How did this enter the conversation/thread?
> 
> Paul's 'contribution' does not even appear on the Archive...

I'm probably guilty. I mentioned in passing the older protocols like 
finger could even be implemented on something like the Pico W with 
MicroPython.

I am confused by the cross-over to Python-list. I only read/post to 
comp.lang.python. Is that echoed to Python-list or vice versa?

>> I haven't worked with CircuitPython lately and don't know if it has
>> pulled in later features.
> 
> Have you (gentle reader) used both and feel able to offer a comparison -
> when to prefer one over the other?

I've only used CircuitPython on the Adafruit Playground Express.

https://circuitpython.org/board/circuitplayground_express/

and MicroPython on the Pico W. Since then Adafruit has expanded their 
collection of boards and support them with CircuitPython.

One difference that makes them hard to compare is the Express has quite a 
few on-board sensors like the Arduino Nano Sense 33, and interfaces to 
them are baked into CircuitPython. 

The Pico W has a wealth of I/O most doubling as I2C, PWM, or A/D with only 
a onboard LED for the mandatory 'hello world' blink code. MicroPython is 
more generic and you may have to import modules for specific external 
devices like the SSD1306 OLED display. That's easily done with Thonny or 
pipkin.

As far as core Python I'd say they're similar. MicroPython is more generic 
and may require more work to set up where Adafruit can match the boards 
they have developed. 

As I said it's been a while but MicroPython has the _threading module so 
you can utilize both cores of the RP2040. Adafruit's new Feather has a 
RP2040 and like the Pico W assumes you'll be using the PIO to externals 
rather than anything onboard so CircuitPython probably has it.

https://www.adafruit.com/product/4884

>From the horse's mouth:

"There is great C/C++ support, unofficial (but really good) Arduino 
support, an official MicroPython port, and a CircuitPython port! We of 
course recommend CircuitPython because we think it's the easiest way to 
get started and it has support with most of our drivers, displays, 
sensors, and more, supported out of the box so you can follow along with 
our CircuitPython projects and tutorials."

I don't know if Adafruit has a RP2350 board yet but they say CircuitPython 
will be even happier on the Pico 2.

https://www.adafruit.com/product/6006

For better or worse there are a lot more choices now than fiddling around 
with the Arduino Uno back in the day. 







-- 
https://mail.python.org/mailman/listinfo/python-list


Re: new here

2024-08-22 Thread dn via Python-list

On 23/08/24 15:43, rbowman via Python-list wrote:

On Fri, 23 Aug 2024 08:36:02 +1200, dn wrote:

On 23/08/24 07:49, rbowman via Python-list wrote:

On Thu, 22 Aug 2024 10:40:52 -0700, Paul Rubin wrote:


The Pico uses MicroPython which is stuck on an old version of Python,
unfortunately.


How did this enter the conversation/thread?

Paul's 'contribution' does not even appear on the Archive...


I'm probably guilty. I mentioned in passing the older protocols like
finger could even be implemented on something like the Pico W with
MicroPython.


The question arose because his message doesn't appear either in the 
conversation/email thread 'here', nor on the Archive. Perhaps not sent 
to the list?




I am confused by the cross-over to Python-list. I only read/post to
comp.lang.python. Is that echoed to Python-list or vice versa?


As I understand it, posts to 'the list' may be made at comp.lang.python 
or by email. Once on the server, messages are reflected back to both. 
Thus, Thunderbird is not set-up to use the newsgroup and keeps 
complaining at me when it's asked to reply to both. So, all 
contributions (from me) enter the server via email.




I haven't worked with CircuitPython lately and don't know if it has
pulled in later features.


Have you (gentle reader) used both and feel able to offer a comparison -
when to prefer one over the other?


I've only used CircuitPython on the Adafruit Playground Express.
https://circuitpython.org/board/circuitplayground_express/
and MicroPython on the Pico W. Since then Adafruit has expanded their
collection of boards and support them with CircuitPython.

One difference that makes them hard to compare is the Express has quite a
few on-board sensors like the Arduino Nano Sense 33, and interfaces to
them are baked into CircuitPython.

The Pico W has a wealth of I/O most doubling as I2C, PWM, or A/D with only
a onboard LED for the mandatory 'hello world' blink code. MicroPython is
more generic and you may have to import modules for specific external
devices like the SSD1306 OLED display. That's easily done with Thonny or
pipkin.


Adding a display to the Pico-W is my next project... After that, gyros 
(am thinking it may not go so well, on balance... hah!).


The Pico-W impresses. Its built-in Wi-Fi/Bluetooth capability makes life 
a lot easier (inside building use).


Apart from the earlier comment, my biggest frustration has come from the 
lack of facilities in Thonny compared with PyCharm - but will pick-up 
skills there, no doubt.


Conversely, (to having a separate radio-chip) I think I prefer the idea 
of being able to connect the Pico to whichever sensor(s) is/are 
actually-required. However, this is applied use - not learning or 'playing'.




As far as core Python I'd say they're similar. MicroPython is more generic
and may require more work to set up where Adafruit can match the boards
they have developed.

As I said it's been a while but MicroPython has the _threading module so
you can utilize both cores of the RP2040. Adafruit's new Feather has a
RP2040 and like the Pico W assumes you'll be using the PIO to externals
rather than anything onboard so CircuitPython probably has it.

https://www.adafruit.com/product/4884

 From the horse's mouth:

"There is great C/C++ support, unofficial (but really good) Arduino
support, an official MicroPython port, and a CircuitPython port! We of
course recommend CircuitPython because we think it's the easiest way to
get started and it has support with most of our drivers, displays,
sensors, and more, supported out of the box so you can follow along with
our CircuitPython projects and tutorials."


Whilst agreeing with the "easiest way to get started" claim, it probably 
also leads to the assumption that it will (later) be easier to run out 
of capability. Hence, that MicroPython would be the better professional 
option - assuming one already knows Python.


Yes, a degree of 'comparing apples with oranges' - and a 
continually-moving target!




I don't know if Adafruit has a RP2350 board yet but they say CircuitPython
will be even happier on the Pico 2.
https://www.adafruit.com/product/6006


No, out in the real-world, the Pico 2 is still vaporware.



For better or worse there are a lot more choices now than fiddling around
with the Arduino Uno back in the day.


True.
Hence the question.
Thanks for the comments!

--
Regards,
=dn
--
https://mail.python.org/mailman/listinfo/python-list