Question: I have a text file and in that text file there are some lines that start with #. What I am trying to do is make new files from the lines that start with #. So for example in the text file if there is a line that starts with the text " # FutureExams " then the script would take that line and make a new file called FutureExams.txt The script I came up with currently runs but doesn't give me any result.

```
find . -name "Data.txt" | while read line; do 
    if [ "$line" == "#"* ]; then 
        touch "$line".txt
    fi
done

```

Perhaps there is a more simpler way of writing the script.

Answer: 
Ah, I got it!

You also need to set the level in your handlers.

In your config file, your [StreamHandler](https://docs.python.org/3/library/logging.handlers.html#logging.StreamHandler) has level `INFO`. That means that even though your root logger `l` is going to emit the `l.debug('adfa')` message, the handler itself is not going to register it. This is intended so you can have a finer control on what messages to log. For instance, let's say you want to have two handlers: one that writes to the terminal and another that writes to a file. In the terminal, it might be OK to output everything, but you might get concerned the files get too big, right? So you create a [FileHandler](https://docs.python.org/3/library/logging.handlers.html#logging.FileHandler) with its level set to `WARN` level, so you could place `l.debug(...)` statements in your code which would get printed to the console, but not to the file.

If you don't wanna change your configuration file, you can do this:

```
l = getLogger()
l.setLevel('DEBUG')
for handler in l.handlers:
    handler.setLevel('DEBUG')
l.debug('adfa')

```

From the docs for [Python 3.1](https://docs.python.org/3.1/library/logging.html) (bit older, but it looks like the sentence I'm gonna paste below was removed in the Python 3.5 docs)

> 
> Why are there two setLevel() methods? The level set in the logger determines which severity of messages it will pass to its handlers. The level set in each handler determines which messages that handler will send on.
> 
> 
>
You've set your log level as `INFO`. You can replace:

```
[logger_root]
level=INFO
handlers=consoleHandler

[handler_consoleHandler]
class=StreamHandler
level=INFO
formatter=simpleFormatter
args=(sys.stdout,)

```

With 

```
[logger_root]
level=DEBUG
handlers=consoleHandler

[handler_consoleHandler]
class=StreamHandler
level=DEBUG
formatter=simpleFormatter
args=(sys.stdout,)

```